日期:2014-05-18  浏览次数:20724 次

JasperReport 打印问题
我用JasperReport在windows环境下调试成功的报表在Unix环境下报错。都是weblogic应用服务器。客户端java控制台报的错误如下:

java.io.EOFException
at   java.io.ObjectInputStream$PeekInputStream.readFully(Unknown   Source)
at   java.io.ObjectInputStream$BlockDataInputStream.readShort(Unknown   Source)
at   java.io.ObjectInputStream.readStreamHeader(Unknown   Source)
at   java.io.ObjectInputStream. <init> (Unknown   Source)
at   net.sf.jasperreports.engine.util.JRLoader.loadObject(JRLoader.java:140)
at   JRPrinterApplet.start(JRPrinterApplet.java:41)
at   sun.applet.AppletPanel.run(Unknown   Source)
at   java.lang.Thread.run(Unknown   Source)

NESTED   BY   :
java.io.EOFException
at   java.io.ObjectInputStream$PeekInputStream.readFully(Unknown   Source)
at   java.io.ObjectInputStream$BlockDataInputStream.readShort(Unknown   Source)
at   java.io.ObjectInputStream.readStreamHeader(Unknown   Source)
at   java.io.ObjectInputStream. <init> (Unknown   Source)
at   net.sf.jasperreports.engine.util.JRLoader.loadObject(JRLoader.java:140)
at   JRPrinterApplet.start(JRPrinterApplet.java:41)
at   sun.applet.AppletPanel.run(Unknown   Source)
at   java.lang.Thread.run(Unknown   Source)

NESTED   BY   :
net.sf.jasperreports.engine.JRException:   Error   loading   object   from   URL   :   http://oa.tjftz.gov.cn:9999/shareentbaseinfosuppportal?dowhat=999&nf=2007&yf=8&ri=1&jnf=2007&jyf=8&jri=30&creatuserid=13919
at   net.sf.jasperreports.engine.util.JRLoader.loadObject(JRLoader.java:145)
at   JRPrinterApplet.start(JRPrinterApplet.java:41)
at   sun.applet.AppletPanel.run(Unknown   Source)
at   java.lang.Thread.run(Unknown   Source)
Caused   by:   java.io.EOFException
at   java.io.ObjectInputStream$PeekInputStream.readFully(Unknown   Source)
at   java.io.ObjectInputStream$BlockDataInputStream.readShort(Unknown   Source)
at   java.io.ObjectInputStream.readStreamHeader(Unknown   Source)
at   java.io.ObjectInputStream. <init> (Unknown   Source)
at   net.sf.jasperreports.engine.util.JRLoader.loadObject(JRLoader.java:140)
...   3   more


----------------------------------------------------

客户端代码
      <OBJECT   codeBase=lib/jinstall-1_5_0-windows-i586.cab#Version=1,5,0,0   height=0   width=0   classid=clsid:8AD9C840-044E-11D1-B3E9-00805F499D93>
                  <PARAM   NAME= "CODE "   VALUE= "JRPrinterApplet.class ">
                  <PARAM   NAME= "ARCHIVE "   VALUE= " <%=request.getContextPath()%> /printer/printer.jar "> ');
                  <PARAM   NAME= "REPORT_URL "   VALUE= " <%=request.getContextPath()%> /shareentbaseinfosuppportal?dowhat=999&nf= <%=nf%> &yf= <%=yf%> &ri= <%=ri%> &jnf= <%=jnf%> &jyf