m_qasim26 Posted April 5, 2007 Share Posted April 5, 2007 Hi, I am using jasper report in my desktop application, in start 5,6 times report is running correctly and then halts the application. Can anyone help me that how this problem can be solved. Below is the code that I am using. Code: Map params = new HashMap(); params.put("Id",25); InputStream reportSource = ClassLoader.getSystemClassLoader().getSystemResourceAsStream("templates/account.jasper"«»); JasperReport jasperReport = (JasperReport) JRLoader.loadObject(reportSource); JasperPrint jasperPrint = JasperFillManager.fillReport(jasperReport, params, DBUtil.getConnection()); JasperViewer viewer = new JasperViewer(jasperPrint,false); viewer.setVisible(true);viewer.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE); reportSource.close(); Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now