◎筱米加步枪◎.Blog

Happy coding

JapserReport导出PDF出现Could not load the following font错误的解决方案

筱米加步枪 posted @ 2012年1月29日 21:39 in [ 开源框架 ] with tags JasperReport , 5005 阅读

年后,将年前的基于JasperReport封装的API移植到Maven工程上,问题不断,其中一个问题就是导出PDF过程中出现如下错误:

 

Could not load the following font :

   pdfFontName   : STSong-Light

   pdfEncoding   : UniGB-UCS2-H

   isPdfEmbedded : true

 

百度了好久没有找到答案,偶然想起之前也有解决相关iText的中文版本问题,请看这篇文章:http://cst.is-programmer.com/posts/18844.html

不过这次有点不同的就是,JasperReport4.5.0 使用的是iText2.1.7版本,分析包名是以com.lowagie开头,所以相应的iTextAsian也应该是com.lowagie.XXX的。

之前出现错误就是导出了其他版本的iTextAsian.jar(com.itextpdf.XXX)。

总之:iText和iTextAsian的包要配套起来就没问题了。

  • 无匹配
HBSE 10th Class Tex 说:
2023年9月21日 21:54 Haryana board Every year Conducted 10th Class Final Exam Month of March to April, This Exam Date Sheet Available at official Website, HBSE has Disclosed the Class Syllabus for Board Exam 2024, Latest Study Materiel were Uploaded in the official website of UP board for Pdf Format Download,Students are Therefore Informed to Collect them From online via the official web portal HBSE 10th Class Textbook 2024 Haryana Class Syllabus 2024 is Available in Hindi, English, Punjab Medium All Subjects,Haryana Board has Recently Upload the HBSE new Syllabus 2024 That come to aid at the Preparation Time for the Students, it gets easy to for the Students to Prepare, Haryana Syllabus 2024 also Called For All the Subjects and Students are advised to Download the Subject wise Study Materiel from online.
HBSE 10th Class Tex 说:
2023年9月21日 21:55

Haryana board Every year Conducted 10th Class Final Exam Month of March to April, This Exam Date Sheet Available at official Website, HBSE has Disclosed the Class Syllabus for Board Exam 2024, Latest Study Materiel were Uploaded in the official website of UP board for Pdf Format Download,Students are Therefore Informed to Collect them From online via the official web portal HBSE 10th Class Textbook 2024 Haryana Class Syllabus 2024 is Available in Hindi, English, Punjab Medium All Subjects,Haryana Board has Recently Upload the HBSE new Syllabus 2024 That come to aid at the Preparation Time for the Students, it gets easy to for the Students to Prepare, Haryana Syllabus 2024 also Called For All the Subjects and Students are advised to Download the Subject wise Study Materiel from online.


登录 *


loading captcha image...
(输入验证码)
or Ctrl+Enter