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

Free Support Forum - aspose.com

Unable to view PDF that is generated using aspose PDF in pdf.js

Hi,

I am unable to view PDF that is generated using aspose PDF in pdf.js.

I have a pdf Viewer that is developed using pdf.js. I am planning to create a PDF Editor using Aspose.PDF.

When I Created PDF using aspose and try to load the same file using PDF.js version 1.5.211, it is throwing error as below:

"TypeError: Cannot read property 'name' of undefined at Annotation (http://localhost/Ux/Src/vendor/pdfjs/pdf.worker.js:40122:44) at AnnotationFactory_create [as create] (http://localhost/Ux/Src/vendor/pdfjs/pdf.worker.js:40059:16) at Page.get annotations [as annotations] (http://localhost/Ux/Src/vendor/pdfjs/pdf.worker.js:41155:44) at http://localhost/Ux/Src/vendor/pdfjs/pdf.worker.js:41544:27 at Promise () at LocalPdfManager_ensure [as ensure] (http://localhost/Ux/Src/vendor/pdfjs/pdf.worker.js:41542:14) at Page_getOperatorList [as getOperatorList] (http://localhost/Ux/Src/vendor/pdfjs/pdf.worker.js:41076:43) at http://localhost/Ux/Src/vendor/pdfjs/pdf.worker.js:42342:14".

Could anybody please help me out on this.

Regards,
Nithin Eate

Hello Nithin,


Thanks for contacting support.

Please confirm that if you tried to open the PDF file, generated through Aspose.Pdf API, in Adobe Reader? In a case if you are facing problem in opening file with Adobe Reader, we will really appreciate if you please share the document and the code snippet which you are using to generate the file. We will test the scenario in our environment and share our finding with you accordingly.

As far as using a PDF viewer is concerned, you may use GroupDocs.Viewer, provided by our sister company, to view the PDF file(s). In case of any further assistance, Please feel free to contact us.


Best Regards,