phantastes Posted April 19, 2011 Share Posted April 19, 2011 Hi,Would anyone know if it is possible to add multiple iFrames to the XHTML output for a report? Could this possibly be done using a custom component?I just wanted to find out if this is even possible before attempting anything.Thank you!Magnus Link to comment Share on other sites More sharing options...
phantastes Posted April 20, 2011 Author Share Posted April 20, 2011 I hear that this can be done using a Generic Element as per this thread in the iReport forum. Would anyone know how this could be achieved? I guess I would need to create multiple html files that the the main html could reference in the iFrame tags. Any thoughts on how much work this would be?Thank you!Magnus Link to comment Share on other sites More sharing options...
phantastes Posted April 28, 2011 Author Share Posted April 28, 2011 I solved this by restyling the XHTML output using jQuery. The short short version:1. Put your subreport in a frame. Set the net.sf.jasperreports.export.html.id property for the frame.2. Restyle the document using: var boxHeight = 350; $("#theFrameID").css('overflow','hidden'); $("#theFrameID").css('overflow-y','scroll'); $("#theFrameID").css('height',boxHeight+'px');That's it. Of course your specific implementation of JasperReports will need to be setup to add the javascript to your xhtml output. You will also need the jQuery library. All the best,Magnus 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