Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

QR group and page number

Posted on 1998-06-16
5
Medium Priority
?
222 Views
Last Modified: 2010-04-04
The report I've got does a grouping of data.. sometimes the subgrouping is one page.. others it is two or more, Is there a way to reset the page counter so it resets with the group.forceNewPage, instead of counting up all the pages in the report. (Each group is a different Customer!)

It would be rather wierd to get the "first page" of a report and see it say "Page # 19" at the bottom!!

Roger Webb
0
Comment
Question by:Whytboy
  • 2
  • 2
5 Comments
 
LVL 8

Expert Comment

by:ZifNab
ID: 1353046
Hi Whytboy,

I guess it's only possible if you use your own counter... Use the events to adjust your counter...

Regards, Zif.
0
 

Author Comment

by:Whytboy
ID: 1353047
Seems kinda odd that that functionality wasnt a thought in the design!  

Roger
0
 
LVL 8

Expert Comment

by:ZifNab
ID: 1353048
Yes, that's my idea also... they've have a reset and a ResetAfterPrint, but I believe this is only for aggregated functions... Zif.
0
 
LVL 10

Accepted Solution

by:
Jacco earned 150 total points
ID: 1353049
For that purpose you shouldn't use the TQRSysData with PageNumber.

You should calculate the page number yourself.

Here is a comment on how to achieve that:

- put a normal TQRLabel qrlPageNo in the page footer of your
  report
- add a integer variable iPageNo to the Reports unit
- in the BeforePrint event of the TQRReport set iPageNo
  variable to 1
- in the OnEndPage event of the report add one to the variable
- in the Before Print of the GroupHeader reset the variable to
  1.
- in the OnPrint event of qrlPageNo label do
    MyLabel.Caption := IntToStr(iPageCount);

This way you create a partially calculated report.

Also fully calculated reports can be designed this way.

I hope I have helped you

Regard Jacco
0
 

Author Comment

by:Whytboy
ID: 1353050
Actually, it works better if the reset back to page one is in the Group Header's AFTER Print.. not sure why.. just had a couple that started on page 2.  

Anyway.. that got me started!!!
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
Introduction Raise your hands if you were as upset with FireMonkey as I was when I discovered that there was no TListview.  I use TListView in almost all of my applications I've written, and I was not going to compromise by resorting to TStringGrid…
Want to learn how to record your desktop screen without having to use an outside camera. Click on this video and learn how to use the cool google extension called "Screencastify"! Step 1: Open a new google tab Step 2: Go to the left hand upper corn…
Is your OST file inaccessible, Need to transfer OST file from one computer to another? Want to convert OST file to PST? If the answer to any of the above question is yes, then look no further. With the help of Stellar OST to PST Converter, you can e…

877 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question