Free Support Forum - aspose.com

Legal Words to PDF resulting size problem

Hello,

When we use Aspose.Word to create a Pdf from a Word document, if the document format is Legal (21,59cm X 35,56cm), the resulting PDF is not the same size (21,59cm X 35,57cm).
It did cause problem in our solution because we do valid the size of the PDF to create lots of same size documents to be print.

I will upload the example I made with the code that was used to create de document.
Example case for Aspose Legal Words to PDF problem.zip (163.0 KB)

@DevSGIPA

Thanks for your inquiry. Please note Aspose.Words mimics MS Word behavior. We have rendered your shared DOCX to PDF using Aspose.Words and MS Word and unable to notice any difference in size. Furthermore, your shared PDF shows that you have created it using Apose.Pdf for .NET.

LETR-LETC_FR_1_MS_Word.pdf (113.6 KB)
AW_176.pdf (52.2 KB)

Best Regards,

Thx for the reply,

In the example, the document was saved in a memory stream as PDF document using Aspose.Words.Document and Aspose.Words.Saving.PdfSaveOptions. After, the pdf from the memory stream was saved again using Aspose.Pdf.Document. I tried saving it directly to pdf using Aspose.Words.Document instead of saving in memory stream and the resulting pdf is also (21,59cm X 35,57cm).

I can’t download the files from your reply, the links doesn’t seem to work.

@DevSGIPA

Please note I am getting 8.5 inch x 14 inch page size in Word and PDF documents. You may convert your Word document to PDF using MS Word and check the page size of resultant PDF document. It should be same as Aspose.Words generated PDF document. However, if the issue persists then please share some details to replicate the issue at our end.

Word Page size
image.png (30.4 KB)

Aspose.Words generated PDF Page size
image.png (4.8 KB)

Aspose.Pdf generated PDF Page size
image.png (5.4 KB)

We will appreciate it if you please share what exact error message you are getting? We will check this issue and will guide you accordingly.

We are sorry for the inconvenience.

Best Regards,

Thx for the reply.

The message if I try to open/download the files from your reply is : “Sorry, this file is private. Only visible to post creator and staff members.”
I am logged in as my user DevSGIPA. Currently, the only file I can open is the zip file from my own post.

@DevSGIPA,

We are sorry for the inconvenience. We are coordinating with the web team to sort out the attachment access issue. Meanwhile, please download the output files from this google drive link.

Best Regards,