0
votes
import com.aspose.words.License;

public void loadLicense() throws LicenseNotFoundException {
    File licenseFile = new File("c:\Aspose.Total.Java.lic");
    if (licenseFile.exists()) {
        try {
            License license = new License();
            InputStream in = new FileInputStream(licenseFile);
            license.setLicense(in);
            in.close();
        } catch (Exception e) {
            e.printStackTrace();
            throw new LicenseNotFoundException(licenseFile.getAbsolutePath() + " not loaded. " + e.getMessage());
        }
    } else {
        throw new LicenseNotFoundException(licenseFile.getAbsolutePath() + " cannot be found.");
    }
}

Exception:

java.io.FileNotFoundException: !META-INF/MANIFEST.MF not found in file:c/oc4j_101350/j2ee/home/applications/xxx/lib/Aspose.Words.jdk14.jar

!META-INF/MANIFEST.MF not found in file:C/oc4j_101350/j2ee/home/applications/xx/lib/Aspose.Words.jdk14.jar

Configuration:

  1. JDK 1.5.06
  2. OC4J Standalone 10.1.3
  3. Aspose.Words.jdk14.jar
1

1 Answers

0
votes

It seems you are using quite old version of Aspose.Words for Java. Please download and try latest version of Aspose.Words for Java. It will resolve the issue.

I'm Tilal, developer evangelist at Aspose.