1000字范文,内容丰富有趣,学习的好帮手!
1000字范文 > net.sf.jasperreports.engine.util.JRFontNotFoundException: Font 华文宋体 is not available to the JVM. S

net.sf.jasperreports.engine.util.JRFontNotFoundException: Font 华文宋体 is not available to the JVM. S

时间:2021-05-04 09:37:23

相关推荐

net.sf.jasperreports.engine.util.JRFontNotFoundException: Font 华文宋体 is not available to the JVM. S

net.sf.jasperreports.engine.util.JRFontNotFoundException: Font ‘xx’ is not available to the JVM.

这是由于没有对应字体导致的, 因为有的japserperreport.jar中的default.jasperreports.properties文件中

net.sf.jasperreports.awt.ignore.missing.font=false

如果字体不存在的话就会出现异常了。

简单的解决方法 :在classpath 中加一个jasperreports.properties文件,加一行

net.sf.jasperreports.awt.ignore.missing.font=true

重新编译。

或是将jasperreport.jar 中的properties文件内容修改,重新打包。

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。