Spire.Doc is a professional Word .NET library specifically designed for developers to create, read, write, convert and print Word document files. Get free and professional technical support for Spire.Doc for .NET, Java, Android, C++, Python.

Thu Feb 23, 2017 4:46 pm

When using Spire.Doc to convert RTF files to PDF files we are seeing the spacing between the middle initial and last names being compressed together to the point that the text is touching. There is a space present in the RTF file before the conversion, but it is not there in the outputted PDF file.

The code i am using to convert the file is:

Dim Doc As New Spire.Doc.Document(path)
Doc.SaveToFile(path.Replace(".rtf", ".pdf"), Spire.Doc.FileFormat.PDF)

the version of Spire.Doc that we are using is 5.8.47.3040

I have attached a sample RTF file that is similar to what we are converting (sensitive information removed).

Is there anything i can do in code to ensure that the spacing isn't compressed when the file is converted to PDF?

Note: This doesn't seem to happen on our development environment, only when run on the test environment

mick0142
 
Posts: 1
Joined: Mon Dec 05, 2016 2:36 am

Fri Feb 24, 2017 2:26 am

Dear mick0142,

Thanks for your inquiry.
I have tested the case you mentioned, unfortunately I don't reproduce the issue you encountered on my side, I have attached the result file, please check. And sorry that there is no code to ensure that spacing on result PDF.

Please provide us the following information so that we can figure out the issue quickly.
1) the sample file can reproduce the issue on your side, because you have removed some datas in the attached document.
2) the output PDF file which has issue for checking.
3) the OS information of the test environment, e.g. Win7 64bit.
4) Region and the Lauguage on control panel, e.g. China Chinese.
kindly note that you could send them to us(support@e-iceblue.com) via email, we promise to keep it confidential and won't use it for any other purpose.

Sincerely,
Betsy
E-iceblue support team
User avatar

Betsy.jiang
 
Posts: 3099
Joined: Tue Sep 06, 2016 8:30 am

Return to Spire.Doc