Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
THRUST SERVICES & TOOLS
CLOUD EDITIONS
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
Unable to export BIRT reports as a .xlsx file
Channamari
<p>Hi,</p>
<p> We have integrated BIRT into our application to handle our reporting needs. We had enabled the reports to generate an HTML report and take the export of these report as an Excel (.xls) File. I am now trying to fetch the exports in the .xlsx format. This is my Code:</p>
<p> </p>
<p><span style="color:#ff0000;"> EXCELRenderOption options = new EXCELRenderOption(); <br>
filePath = folder+"/GeneratedReports/"+ SessionID + "/" + reportName + ".xlsx";<br>
options.setOutputFormat("xlsx");<br>
options.setOutputFileName(filePath);<br>
task.setEmitterID("uk.co.spudsoft.birt.emitters.excel.XlsxEmitter"); <br>
task.setRenderOption(options);</span><br>
</p>
<p> </p>
<p> However, I am getting this exception after i put in these changes:</p>
<p> </p>
<p>Jul 25, 2016 6:42:58 PM org.eclipse.birt.report.engine.api.impl.EngineTask handleFatalExceptions<br>
SEVERE: An error happened while running the report. Cause:<br>
java.lang.NullPointerException at uk.co.spudsoft.birt.emitters.excel.ExcelEmitter.end(ExcelEmitter.java:273) at org.eclipse.birt.report.engine.emitter.CompositeContentEmitter.end(CompositeContentEmitter.java:65)<br>
at org.eclipse.birt.report.engine.api.impl.RunAndRenderTask.doRun(RunAndRenderTask.java:183)<br>
at org.eclipse.birt.report.engine.api.impl.RunAndRenderTask.run(RunAndRenderTask.java:77)<br>
at ubq.reportingToolFramework.BirtReportMasterServlet.handleGet(BirtReportMasterServlet.java:238)<br>
at ubq.desktop.UHttpServlet.doGet(UHttpServlet.java:347)<br>
at javax.servlet.http.HttpServlet.service(HttpServlet.java:620)<br>
at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)<br>
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)<br>
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)<br>
at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)<br>
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)<br>
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)<br>
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:220)<br>
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:122)<br>
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:501)<br>
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:170)<br>
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:98)<br>
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:950)<br>
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116)<br>
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:408)<br>
at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1040)<br>
at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:607)<br>
at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:315)<br>
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)<br>
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)<br>
at java.lang.Thread.run(Thread.java:745)..</p>
<p> </p>
<p>Any help would really be appreciated.. Thanks in advance.<br>
</p>
Find more posts tagged with
Comments
Clement Wong
<p>Do these reports convert to XLSX using the Spudsoft emitter in the Designer?</p>
<p> </p>
<p>As a baseline, from your application, are you able to export any of the sample reports to Excel?</p>
<p> </p>
<p>Also, are you able to use a different emitter? Does that work with the sample reports? Or work with your reports?</p>
Channamari
<p>Thanks for the reply.</p>
<p> </p>
<p>Firstly, Yes, i am able to export the report in xlsx format from the designer and I am able to take the export of Excel files in the .xls fromat. However i run into this error when i change the emitterID to the spudsoft Xlsx emitters..</p>
<p> </p>
<p>The version of BIRT that I am using is BIRT 4.4.1, the Java version used is JDK 7, and the application is deployed on a Tomcat 7 server..</p>
<p> </p>
<p>I have not tried the export with other emitters.. I will try and get back to you..</p>