Monday, February 3, 2014

jasperviewer closes main application

at the time of closing jasperviewer report that is opened up, main application window is closed at the same time.To get rid form this problem:

in the constructor of JasperViewer there is boolean indicating whehter it should perform an exit on close.

jasperReport = JasperCompileManager.compileReport( "reportloh.jrxml");
jasperPrint = JasperFillManager.fillReport( jasperReport, parameters, conn);
JasperViewer jv = new JasperViewer( jasperPrint, false );
jv.viewReport( jasperPrint, false );
 

No comments: