Not Displaying Blank Page

Stimulsoft Reports.NET discussion
Post Reply
TimWoods
Posts: 10
Joined: Thu Mar 27, 2014 9:56 pm

Not Displaying Blank Page

Post by TimWoods »

I'm working on a report that has two types of investors-isgroup and notgroup.

I have a report set up with two pages (page1 and page2. Page1 has a databand that filters only for isgroup. Page2 has a databand has a filter that filters for notgroup.

The idea is to run the report over all of the isgroup records first, and the second page runs over all of the notgroup records. It works great unless there are no records for the second page. When there are no records for the second page, a blank page is displayed.

I would like to get rid of the blank page if there are no notgroup records when the report is run. How?
HighAley
Posts: 8430
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

Re: Not Displaying Blank Page

Post by HighAley »

Hello.

The easiest way is to move content of second page to the first one and set the New Page Before property of the first component from the second page.

Other way is to check if there any data for second page and disable it in the Before Print event of the second page.

Let us know if you need additional help.

Thank you.
TimWoods
Posts: 10
Joined: Thu Mar 27, 2014 9:56 pm

Re: Not Displaying Blank Page

Post by TimWoods »

Moving the second page content to the first page worked.

To help increase my own knowledge, how would I check if there is any data for the second page before the second page runs?
HighAley
Posts: 8430
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

Re: Not Displaying Blank Page

Post by HighAley »

Hello.

Unfortunately, we don't know structure of your data but one of the ways is to use next property of the Data Source DataSourceName.Count.

Thank you.
Post Reply