Jump to content
We've recently updated our Privacy Statement, available here ×

Printing list of reports with one print_dialog


AlfredSniff

Recommended Posts

Hi,

 

I'd like to print several jasperReport and I'd like to choose the printer and it's parameters. I want to choose these parameters only ONE time for every reports. For example, I have 30 reports to print and I want to choose the printer parameters only once.

 

I wrote thise :

 

Code:

exporter.setParameter(JRExporterParameter.JASPER_PRINT_LIST, lstReports);
exporter.setParameter(JRPrintServiceExporterParameter.DISPLAY_PAGE_DIALOG,
Boolean.FALSE);
exporter.setParameter(JRPrintServiceExporterParameter.DISPLAY_PRINT_DIALOG,
Boolean.TRUE);

 

Actually it works but the print dialog box appears for each occurence of my JasperList and I want it to display only one time. Is there a way to do that? Maybe with a loop? How to keep parameters from the printDialog box?

Thanks in advance for answers

Post edited by: AlfredSniff, at: 2007/07/10 17:07

Link to comment
Share on other sites

  • Replies 2
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Hi,

 

In JasperReports v1.3.3 were introduced 2 other export parameters in conjunction with those you've already set, in order to solve that kind of problem.

You should update the JasperReports version, and set to true the JRPrintServiceExporterParameter.DISPLAY_PRINT_DIALOG_ONLY_ONCE if you want to see the print dialog only once, or the JRPrintServiceExporterParameter.DISPLAY_PAGE_DIALOG_ONLY_ONCE, for the same behaviour of the page dialog.

 

hth,

sanda

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...