JasperReports Server: HTML Component issue

2019-07-31 02:01发布

I have a report with HTML component in JasperReports 5.1.

Its working fine in iReport but not working in JasperReports Server Professional 5.0.

org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found     starting with element 'hc:html'. 
One of '{"http://jasperreports.sourceforge.net/jasperreports":component}' is expected.

I tried to add the following properties in JasperReports.properties file but it didn't work:

net.sf.jasperreports.extension.registry.factory.htmlelement=net.sf.jasperreports.extensions.HtmlElementExtensionsRegistryFactory

net.sf.jasperreports.extension.registry.factory.htmlcomponent=net.sf.jasperreports.components.html.HtmlComponentExtensionsRegistryFactory

Please suggest how can I fix this.

2条回答
Lonely孤独者°
2楼-- · 2019-07-31 02:10

for jasper reports server 6.3.0.final we put the eclipse/plugins/com.jaspersoft.studio.html_6.3.2.final.jar!lib/htmlcomponent.jar (Eclipse Neon) into ...\jasperreports-server-cp-6.3.0\apache-tomcat\webapps\jasperserver\WEB-INF\lib, restarted it and it worked :)

查看更多
劫难
3楼-- · 2019-07-31 02:12

One of my colleague suggested the soluntion and it worked.

copy

 jasperreports-htmlcomponent-5.0.1.jar from <JaspersoftiReport-5.1.0>\ireport\modules\ext   

paste to

 Web-Inf\lib  folder of jasperserver

Thanks

Ankush

查看更多
登录 后发表回答