how to print a report that is not consecutive pages

Stimulsoft Reports.NET discussion
Post Reply
miguels
Posts: 27
Joined: Tue Jun 23, 2009 5:05 pm

how to print a report that is not consecutive pages

Post by miguels »

hello, I would love saver if there is any method to print a report but not straight out too, I have 10 sheets and need to print 1,10,2,9,3,8,4,7,5,6 and not 1 to 10
Alex K.
Posts: 6488
Joined: Thu Jul 29, 2010 2:37 am

how to print a report that is not consecutive pages

Post by Alex K. »

Hello,

It is impossible to do it from the viewer. But from the application code you can sort pages.

Thank you.
miguel
Posts: 14
Joined: Tue Apr 21, 2009 10:32 am
Location: sinaloa

how to print a report that is not consecutive pages

Post by miguel »

I can spend an example of how to do it pls ... of 2 ways if not too much trouble
Alex K.
Posts: 6488
Joined: Thu Jul 29, 2010 2:37 am

how to print a report that is not consecutive pages

Post by Alex K. »

Hello,

Please see the sample code:

Code: Select all

StiReport originalReport = new StiReport();
originalReport.Load();
originalReport.Render();

StiReport printReport = new StiReport();
printReport.Render();
printReport.RenderedPages.Clear();
printReport.RenderedPages.Add(originalReport.RenderedPages[2]);
printReport.RenderedPages.Add(originalReport.RenderedPages[0]);
...
printReport.Show();
Thank you.
Post Reply