Determine if subreport length is over 1 page (1 Viewer)

jubb

Registered User.
Local time
Today, 10:36
Joined
Jul 27, 2005
Messages
50
Hi all,

I am setting up a report to print out mailing labels with outstanding invoives printed on the back of the mailing label.

I have a main report which has the mailing details for the label and a subreport which prints the outstanding invoices on a second page of the report. ie each family has a 2 page report.

The report works fine except for when there is more than 1 page of invoices for a person as the report is printed double sided.

To notify the user if there is a problem prior to printing I need to determine if the subreport lenght is greater than 1 page long and display a message box informing the user not to print the report.

I have tried using using me.pages > 1 in the on page event of the subreport to determine if the subreport is over 1 page to no avail. The .pages doesn't seem to return a value when used in a subreport. (Checked this with a message box displaying me.pages)

Also tried report_rptName.pages - no success that way either.

Any help would be greatly appreciated.

Thanks
Jubb
 

jubb

Registered User.
Local time
Today, 10:36
Joined
Jul 27, 2005
Messages
50
Don't worry, came up with a work around, calculated the maximum number of invoices that could fit on a page then check to make sure no families invoices is greater than that amount, if they are I skip that record in my report and print a list of families whose mailing labels were skipped.

Thanks Anyhow
 

Users who are viewing this thread

Top Bottom