manishamauni Posted October 6, 2006 Share Posted October 6, 2006 Hello,I am using same JasperPrint instance for creating my report in html format and pdf format using JasperExportManager.exportReportToHtmlFile(jasperPrint, "test/MainReport.html" ); andJasperExportManager.exportReportToPdfFile(jasperPrint, "test/MainReport.pdf") functions respectively. I can print my html report both in portrait and landscape orientation while I am not able to do so for pdf report.I tried setting JRReport.ORIENTATION_LANDSCAPE but it’s just ignoring the setting. I want to give user flexibility of printing pdf report in portrait as well as landscape…. Please help….. ThanksManisha Link to comment Share on other sites More sharing options...
Teodor Danciu Posted October 11, 2006 Share Posted October 11, 2006 Hi, Changing page orientation is not sufficient.It is actually a page size change. The page width should become the page height and viceversa.The orientation attribute is used only by some exporters (including the PDF exporter) that need to know the document is in landscape format so that printer turns the page when printing. Having said all that, I'm not sure what you are trying to achieve is possible, since PDF is an absolute positioning layout and by only changing the page orientation, the content will not adapt automatically to fit into a wider page layout. I hope this helps.Teodor Link to comment Share on other sites More sharing options...
manishamauni Posted October 16, 2006 Author Share Posted October 16, 2006 Thanks Teodor!!Appreciate your help.Post edited by: manishamauni, at: 2006/10/16 16:04 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