header image 2

JasperReport錯誤訊息

5 10 月, 2006 · No Comments

在使用JasperReports某些情況下會出現下面的錯誤訊息
Print JasperReports encountered this error :
net.sf.jasperreports.engine.JRException: Could not load the following font :

pdfFontName : MSung-Light
pdfEncoding : Cp1252
isPdfEmbedded : true
最早是使用0.5.2的版本無此問題,但改用1.2.4版後,就開始有此問題發生
原因是在於xml or jrxml檔內多了下面四行資料

因此當利用ireport設計好版面後xml or jrxml檔內
每個textField內的textElement被設定為Barcode之類的屬性,如下所示

如此會照程使用程式編譯時會出現上述所說的錯誤訊息。
修改方式就是將xml or jrxml檔內

這段刪除
然後將每個textField內的textElement被設定為Barcode之類的屬性,修正為下列所示

修改後,往後利用ireport修改xml or jrxml檔
則相關字型設定變不會被更動到。

Tags: 技術通報

0 responses so far ↓

  • There are no comments yet...Kick things off by filling out the form below.

Leave a Comment