使用JasperReports导出PDF时出现异常

时间:2011-05-30 12:50:04

标签: java pdf jasper-reports

我正在尝试使用JasperReports Java库导出PDF。

我在尝试执行应用程序时遇到异常:

    net.sf.jasperreports.engine.JRRuntimeException: Unknown hyperlink target 0
    at net.sf.jasperreports.engine.JRHyperlinkHelper.getLinkTarget(JRHyperlinkHelper.java:273)
    at net.sf.jasperreports.engine.base.JRBaseTextField.normalizeLinkTarget(JRBaseTextField.java:317)
    at net.sf.jasperreports.engine.base.JRBaseTextField.readObject(JRBaseTextField.java:381)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:974)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1848)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1752)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1328)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:350)
    at java.util.ArrayList.readObject(ArrayList.java:593)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:974)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1848)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1752)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1328)
    at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1946)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1870)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1752)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1328)
    at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1946)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1870)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1752)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1328)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:350)
    at net.sf.jasperreports.engine.util.JRLoader.loadObject(JRLoader.java:92)
    at net.sf.jasperreports.engine.JasperFillManager.fillReport(JasperFillManager.java:515)
    at nl.fontys.hblogistics.util.BillViewer.exportPDF(BillViewer.java:33)
    at nl.fontys.hblogistics.util.BillViewer.main(BillViewer.java:18)

我找不到任何解决方案。

感谢。

0 个答案:

没有答案