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.

Mon May 10, 2021 5:21 am

Hi Team,

We get java.lang.IllegalStateException: Cannot find table 'loca' in the font file. error while converting the word file to PDF on Linux server. Same code works well on the Windows.

If it is related to any specific font, then is it avoidable without installing the same?

Any help on the font installation in Linux will be helpful as well.

Error dump:
java.lang.IllegalStateException: Cannot find table 'loca' in the font file.
at com.spire.office.packages.sprCyC.spr (Unknown Source)
at com.spire.office.packages.sprCyC.spr (Unknown Source)
at com.spire.office.packages.sprHfE.spr (Unknown Source)
at com.spire.office.packages.sprHfE.spr (Unknown Source)
at com.spire.office.packages.sprdHE.spr (Unknown Source)
at com.spire.office.packages.sprsRC.spr (Unknown Source)
at com.spire.office.packages.sprBsC.spr (Unknown Source)
at com.spire.office.packages.sprSSC.spr (Unknown Source)
at com.spire.office.packages.sprsRC.spr (Unknown Source)
at com.spire.office.packages.sprPSC.spr (Unknown Source)
at com.spire.office.packages.sprPSC.spr (Unknown Source)
at com.spire.office.packages.sprPSC.spr (Unknown Source)
at com.spire.office.packages.sprvsC.spr (Unknown Source)
at com.spire.office.packages.sprMSC.spr (Unknown Source)
at com.spire.office.packages.sprbRC.spr (Unknown Source)
at com.spire.office.packages.sprHtC.spr (Unknown Source)
at com.spire.office.packages.sprHfE.spr (Unknown Source)
at com.spire.office.packages.sprHfE.spr (Unknown Source)
at com.spire.doc.Document.spr (Unknown Source)
at com.spire.doc.Document.saveToFile(Unknown Source)

Thanks in advance.

pr20080798
 
Posts: 148
Joined: Wed Jan 20, 2021 1:15 pm

Mon May 10, 2021 8:40 am

Hello,

Thanks for your inquiry.
Kindly note that when using our Spire.Doc to convert word file to PDF, you need to install all fonts used in the word file in your system, otherwise the application may throw errors. Please make sure you have installed the corresponding fonts on your environment. Also, our Spire.Doc supports using noninstalled font when converting Doc to PDF like the following link:
https://www.e-iceblue.com/Tutorials/Jav ... -Java.html
If there are still any issues, please provide your input file to help us investigate further. You could send it to us(support@e-iceblue.com) via email. Thanks in advance.

Sincerely,
Brian
E-iceblue support team
User avatar

Brian.Li
 
Posts: 1271
Joined: Mon Oct 19, 2020 3:04 am

Mon May 17, 2021 8:38 am

Hello,

Has your issue been resolved? Any feedback will be greatly appreciated.

Sincerely,
Brian
E-iceblue support team
User avatar

Brian.Li
 
Posts: 1271
Joined: Mon Oct 19, 2020 3:04 am

Fri Jun 18, 2021 2:14 am

Hi,

Could you please help me on exporting the fonts from word and install the same on Linux?

Thanks in advance!!

pr20080798
 
Posts: 148
Joined: Wed Jan 20, 2021 1:15 pm

Fri Jun 18, 2021 9:53 am

Hello,

Thanks for your reply.
The internal data of the word document only contains the font information used, and there is no font file embedded in it. So it is not possible to export fonts from the Word file.
We recommend you can make a copy of all the fonts installed in your Windows system and then install them in your Linux system.

Sincerely,
Brian
E-iceblue support team
User avatar

Brian.Li
 
Posts: 1271
Joined: Mon Oct 19, 2020 3:04 am

Sun Jul 18, 2021 6:28 am

Thanks Brian.

We have fixed this issue by installing the necessary fonts.

Thank you for the help.

pr20080798
 
Posts: 148
Joined: Wed Jan 20, 2021 1:15 pm

Mon Jul 19, 2021 1:44 am

You are welcome.
If you encounter any issues related to our products in the future, please feel free to contact us.

Sincerely,
Brian
E-iceblue support team
User avatar

Brian.Li
 
Posts: 1271
Joined: Mon Oct 19, 2020 3:04 am

Return to Spire.Doc