Kannan_S Posted October 3, 2006 Share Posted October 3, 2006 hi all,we are into a web reporting project.we make use of jasper reports.its really good to see our reports in jasper reports formats. we have tried to export it into many formats and we have succeeded in doing that. we are instructed to show only 20 rows per view. we have done that by adjusting the report height. but we have a problem. The exported file ,say an xls file or a csv file ,they have the headers(field name) repeated ,which we do not require, for every page. Is there any parameter in the JRExporterParameter which will stop or avoid this repitition of field names in every page? Please help Link to comment Share on other sites More sharing options...
lucianc Posted October 3, 2006 Share Posted October 3, 2006 Report pagination is done during report fill, hence a filled report (JasperPrint object) is already paginated. It's not possible to change the pagination during export. That's way the parameter that controls the pagination (JRParameter.IS_IGNORE_PAGINATION) is a fill parameter. Regards,Lucian Link to comment Share on other sites More sharing options...
Kannan_S Posted October 3, 2006 Author Share Posted October 3, 2006 thanks for the reply lucian. but thats not the requirement i was expecting. the user should see only 20 rows in a view. The user should be presented with page numbers to view the remaining data and at the same time if the user wants to export the data into a csv file,the csv file should not have the headers repeated as each page. So no other way? anything as a feature request? Link to comment Share on other sites More sharing options...
rsilverns.sympatico.ca Posted October 3, 2006 Share Posted October 3, 2006 CSV Exporting is done based upon a strict algorithm. Using features like page headers etc. are not really recommended when exporting to CSV. A good article to outline some best practices for CSV exporting is... http://jasperforge.org/sf/wiki/do/viewPage/projects.jasperreports/wiki/FAQ9 hth,Robin Link to comment Share on other sites More sharing options...
Teodor Danciu Posted October 3, 2006 Share Posted October 3, 2006 Hi, Check the supplied /demo/samples/nopagebreak sample.Note that there is also a built-in fill time parameter called IS_IGNORE_PAGINATION that when turned to Boolean.TRUE will cause the engine to ignore the page height and all the page break related settings in JRXML to produce a document with a single very large page. I hope this helps.Teodor Link to comment Share on other sites More sharing options...
Kannan_S Posted October 4, 2006 Author Share Posted October 4, 2006 its great to get the answer from the admin.Thanks Teodord.i can very well use IS_IGNORE_PAGINATION boolean variable in jrxml,but at the same time i have to show the user only 20 rows.So i have to go for pagination and when exporting to CSV or any other format the field name should not be repeated.i think only any one of the two could be done,both cannot be done simultaneoulsy am i right?Post edited by: Kannan_S, at: 2006/10/04 06:35 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