We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Failed to load document on Windows (635)


When I try to load the attached document on Windows, it fails with this exception:

Exception in thread “main” java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.jdt.internal.jarinjarloader.JarRsrcLoader.main(JarRsrcLoader.java:58)
Caused by: com.aspose.words.FileCorruptedException: The document appears to be corrupted and cannot be loaded.
at com.aspose.words.FileFormatUtil.zzZ(Unknown Source)
at com.aspose.words.Document.zzY(Unknown Source)
at com.aspose.words.Document.zzZ(Unknown Source)
at com.aspose.words.Document.(Unknown Source)
at com.aspose.words.Document.(Unknown Source)
at com.aspose.words.Document.(Unknown Source)

On the other side, it works fine on Linux and OSX.

Here’s the code I use:

InputStream inputStream = new FileInputStream(“FFs-get-over-Tk.-37.51-crore-as-honorarium-allowance-in-Kishoreganj.doc”);
<span style=“font-family: “Courier New”;”>
<span style=“font-family: “Courier New”;”> Document document = new Document(inputStream);


I’m using Aspose.Words for Java 16.11.0.

Can you check this?


Hi Zeljko,

Thanks for your inquiry. We have tested the scenario using latest version of Aspose.Words for Java 16.11.0 and have not found the shared issue. Please make sure that you are using Aspose.Words for Java 16.11.0 and same attached Word document.

Hi Tahir,

I’m already using Aspose.Words for Java 16.11.0 and the file I attached in the previous post.

Maybe some environment details will help you:

Windows 7 Ultimate SP1 x64

java version "1.8.0_101"
Java™ SE Runtime Environment (build 1.8.0_101-b13)
Java HotSpot™ Client VM (build 25.101-b13, mixed mode)

Eclipse IDE for Java Developers
Version: Neon.1a Release (4.6.1)
Build id: 20161007-1200

Can you check it again with similar environment?

Hi Zeljko,

Thanks for sharing the detail. We have tested the scenario and have managed to reproduce the same issue at our side. For the sake of correction, we have logged this problem in our issue tracking system as WORDSJAVA-1463. You will be notified via this forum thread once this issue is resolved.

We apologize for your inconvenience.
Hi Zeljko,

Thanks for your patience. It is to inform you that the issue which you are facing is actually not a bug in Aspose.Words. So, we have closed this issue (WORDSJAVA-1463) as 'Not a Bug'.

Your document has the image from the following source.


Eclipse uses Windows' default encoding which is 1252. So, the output is as follow:


Please set up UTF-8 as default encoding for your project to fix this issue. See the attached image for detail.