Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Page Numbers
Message
From
06/01/2003 19:18:59
 
General information
Forum:
Visual FoxPro
Category:
Reports & Report designer
Title:
Miscellaneous
Thread ID:
00738114
Message ID:
00738604
Views:
42
Hi Sergey,

This looks like a good workaround, however what Ravi did in his report should not be causing this problem, it was simply a combination of a page title band and a group band set to reset page number to 1. This combination caused _pageno to be 1,1,2,3,... when the group on the first page spanned more than 1 page. I could reproduce it on every report that had this combination. If you remove the title band or remove the reset page number for the group band, _pageno increments properly. I could remove the title band and put the title band objects in the page header with print when condition to only print on page 1 and it works fine.

I would consider this a bug (albeit a minor one). Do you know if this has been fixed in later (post VFP6 SP5) versions? I didn't realize this happened, so I now have several reports that I will have to employ this workaround.





>You can create your own page counter as shown in Re: _Pageno Not Advancing Message #610944.
>
>>Hi Ravi,
>>
>>It appears that you have stumbled upon a bug in the report writer that I did not know was there, perhaps others have discovered it.. Your report has a title band that has a couple of labels,fields and lines that print on the first page only as the title band is designed to do. You also have a group band in the report which is set to Start a new page when group changes and Reset to page 1 when the group changes.
>>
>>As you noted, it has _pagno being printed on each page but did not seem to be incrementing properly (you observed that it remained page 1 or each page). I had to add more records to your table to observe exactly what was happening, but it appears that when you have a grouping like this (resetting group to page 1), and have a title band, the _pageno increments improperly after the first page like 1, 1, 2, 3, 4 Group change, 1, 2, 3, 4, Group change, 1, 2, 3, etc.
>>
>>This only happens when you have a title band and a grouping set to reset page number to 1. If you remove the title band, or uncheck reset to page 1, the first page increments _pageno properly. I tried this on some of my reports and observed the same thing, So I would say that this is a bug in VFP 6.0 SP5. Does anyone know if this has been fixed in VFP7 or 8?
>>
>>You probably would have never found this had your first data group been less than 1 page.
>>
>>I removed the title band and placed the objects that you had in the title band in the page header with a print when _pageno = 1 to simulate the title band and it increments your page numbers OK.
>>
>>
>>>>If you can email me a table (made from your cursor unpaids) with the the report form I will look into it.
>>>
>>>Thanks Elmer. It should be in your inbox by now.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform