Exportar p/ Excel usando JSP

Olá pessoal, blzz

Alguém já exportou para EXCEL um .jasper usando JSP …
gostaria de algumas dicas … consegui fazer em html e pdf, mas pra xls ta dando uns erros.

valeu, t+

Marcelo, você tem que nos ajudar primeiro para que possamos te ajudar.

Que erros?

Fala Lipe, td blzz

Certo, é q estou montando o JSP pra exportar pra excel, mas as dúvidas são mtas, se alguém tivesse algum modelo pra me ajudar seria legal.
O código o a mensagem de erro estão logo abaixo.

valeu, t+

if ( saida.equals("EXCEL")){ File sourceFile = new File(sourceFileName); JasperPrint jprint = (JasperPrint)JRLoader.loadObject(sourceFile); File destFile = new File(sourceFile.getParent(), jprint.getName() + ".xls"); JRXlsExporter exporter = new JRXlsExporter(); exporter.setParameter(JRExporterParameter.JASPER_PRINT, jprint); exporter.setParameter(JRExporterParameter.OUTPUT_FILE_NAME, destFile.toString()); exporter.setParameter(JRXlsExporterParameter.IS_ONE_PAGE_PER_SHEET, Boolean.FALSE); exporter.exportReport(); response.sendRedirect( pageRoot + destFile ); }

javax.servlet.ServletException: No input source supplied to the exporter. org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:825) org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:758) org.apache.jsp.report.fazenda_005fproducao_005fga_jsp._jspService(fazenda_005fproducao_005fga_jsp.java:180) org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)

Ve se um desses nao te ajuda…

:arrow: http://www.guj.com.br/posts/list/0/18697.java#97533

Valeu? até… :thumbup:
[]'s