Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Additional Page Counter in Rpt w/ sub reports

Status
Not open for further replies.

denko

Programmer
May 17, 2001
70
US
I've got pretty complicated report, it contains about 15 subreports, and I force page brakes almost before every sub report. I also reset page counter before beginning of two different groups.
I need to create another page counter that just counts pages and ignores any resets. It should work like something that you'd see in the right top corner of a preview window in Crystal - 1 of 129. I can not use any of a page counter functions since i reset them.
I tried to use this formula

WhilePrintingRecords ;
NumberVar PageCounter := PageCounter + 1 ;
"Page " + ToText(PageCounter, 0)

but it does not work correctly. Conter starts from 2 and if I move back and force in the report, counter starts to repeat page number like Page 2, Page 3, Page 4, Page 4, Page 4, Page 4, Page 8, Page 9, Page 10 and then again it would repeat a certain page number. I know that it caused by my grouping and page braking but can not modify groups and brakes.
I'm using CR Version 6 and Visual Basic. Any help will be appreciated.
Thanks
denko
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top