iReport 子报表 Error loading object from URL
2012-07-24 14:53
267 查看
今天,制作iReport子报表出现一个头疼的问题,与之前子报表做法几乎一样,jasper文件路径也正确,通过浏览器可以下载;
但是偏偏SUBREPORT_DIR设置为"F:\\iReport-3.0.0\\"可以运行,而设置"http://localhost:8080/"类似路径却始终不行,为何呢?
最后,经过个各种尝试,终于找到了原因,解决方案:我的子报表中有空格,编译出的jasper文件也是,浏览器中读不出来,空格改成下划线即可。
(附:jasperreports-3.0.0相关API:http://www.docjar.com/projects/jasperreports-3.0.0-project-code.html)
但是偏偏SUBREPORT_DIR设置为"F:\\iReport-3.0.0\\"可以运行,而设置"http://localhost:8080/"类似路径却始终不行,为何呢?
net.sf.jasperreports.engine.JRException: Error loading object from URL : http://localhost:8080//xxx_subreport0.jasper at net.sf.jasperreports.engine.util.JRLoader.loadObject(JRLoader.java:149) at net.sf.jasperreports.engine.util.JRLoader.loadObjectFromLocation(JRLoader.java:256) at net.sf.jasperreports.engine.fill.JRFillSubreport.evaluateSubreport(JRFillSubreport.java:311) at net.sf.jasperreports.engine.fill.JRFillSubreport.evaluate(JRFillSubreport.java:260) at net.sf.jasperreports.engine.fill.JRFillElementContainer.evaluate(JRFillElementContainer.java:275) at net.sf.jasperreports.engine.fill.JRFillBand.evaluate(JRFillBand.java:426) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillColumnBand(JRVerticalFiller.java:1380) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillDetail(JRVerticalFiller.java:692) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReportStart(JRVerticalFiller.java:255) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReport(JRVerticalFiller.java:113) at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:888) at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:791) at net.sf.jasperreports.engine.fill.JRFiller.fillReport(JRFiller.java:63) at net.sf.jasperreports.engine.JasperFillManager.fillReport(JasperFillManager.java:402) Caused by: java.io.IOException: Server returned HTTP response code: 505 for URL: http://localhost:8080//xxx_subreport0.jasper at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1441) at java.net.URL.openStream(URL.java:1010) at net.sf.jasperreports.engine.util.JRLoader.loadObject(JRLoader.java:143) ... 86 more
最后,经过个各种尝试,终于找到了原因,解决方案:我的子报表中有空格,编译出的jasper文件也是,浏览器中读不出来,空格改成下划线即可。
(附:jasperreports-3.0.0相关API:http://www.docjar.com/projects/jasperreports-3.0.0-project-code.html)
相关文章推荐
- ireport 找不到子报表:Could not load object from location
- ireport3.7导出报表报异常:Error retrieving field value from bean :XX ;NoSuchMetho dException:Unknown proper
- Cloning EBS from Linux 5 to Linux 6 Fails: "Error While Loading Shared Libraries: libclntsh.so.10.1
- Centos中error while loading shared libraries: libstdc++.so.5: cannot open shared object file: No such file or directory
- [RK_2014_0920]ubuntu下,使用ldconfig解决:error while loading shared libraries: libpcap.so.1: cannot open shared object file: No such file or directory
- 解决./exam5-5: error while loading shared libraries: libdemo.so: cannot open shared object file:
- .JRException:Error loading object
- error while loading shared libraries: libz.so.1: cannot open shared object file: No such file or dir
- ffmpeg: error while loading shared libraries: libavdevice.so.52: cannot open shared object file: No
- QtOpenCV: error while loading shared libraries: libopencv_core.so.3.2: cannot open shared object fil
- python3.5: error while loading shared libraries: libpython3.5m.so.1.0: cannot open shared object file: No such file or directory
- error while loading shared libraries: libnet.so.9: cannot open shared object file: No such **解决方法
- protoc: error while loading shared libraries: libprotoc.so.8: cannot open shared object file: No suc
- Error While Loading Shared Libraries, Cannot Open Shared Object File
- Error using * LAPACK loading error: dlopen: cannot load any more object with static TLS
- error while loading shared libraries: libpcap.so.1: cannot open shared object file: No such file or
- jps: error while loading shared libraries: libjli.so: cannot open shared object file: No such file..
- 解决error while loading shared libraries: libXXX.so.X: cannot open shared object file: No such file
- Eclipse error: The type java.lang.Object cannot be resolved. It is indirectly referenced from the required .class files
- ./nginx: error while loading shared libraries: libcrypto.so.1.1: cannot open shared object file: No