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

Free Support Forum - aspose.com

The Format Problem of Converting Word File to Pdf File

I used Aspose.Word to generate a Word file, and generated a docx file and a pdf file locally.
There is no problem with the style of the docx file .But there is a style problem on the pdf.
I expect the style of the pdf file content to be similar to the style of the docx file content.
What should i do?
Please tell me, Thanks.
This is Pdf file content.
1630583284(1).png (6.5 KB)
This is docx file content.
1630583322(1).png (2.8 KB)

@david135

Please note that Aspose.Words requires TrueType fonts when rendering document to fixed-page formats (JPEG, PNG, PDF or XPS). You need to install fonts that are used in your document on the machine where you are converting documents to PDF. Please refer to the following articles:

Using TrueType Fonts
Manipulating and Substitution TrueType Fonts

If you still face problem, please ZIP and attach your input Word document along with problematic and expected output PDF here for testing. We will investigate the issue and provide you more information on it.

May I ask why there is no such problem when saving as Pdf directly in Word?

And My OS is Windows11. Fonts are always there

@david135

To ensure a timely and accurate response, please attach the following resources here for testing:

  • Your input Word document.
  • Please attach the output PDF file that shows the undesired behavior.
  • Please attach the expected output PDF file that shows the desired behavior.
  • Please create a standalone console application (source code without compilation errors) that helps us to reproduce your problem on our end and attach it here for testing.

As soon as you get these pieces of information ready, we will start investigation into your issue and provide you more information. Thanks for your cooperation.

PS: To attach these resources, please zip and upload them.