Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Get recno() of running report
Message
From
31/08/2012 15:59:06
 
 
To
31/08/2012 15:05:25
General information
Forum:
Visual FoxPro
Category:
Reports & Report designer
Miscellaneous
Thread ID:
01552160
Message ID:
01552184
Views:
59
>>>When running a report, I would like to figure out which record number the current page is in the underlying cursor, if that is possible.
>>>I have a reference to the Extension handler, and the previewform. During the preview, whichever page I have selected, the cursor is at the last record. Is there a reference somewhere where I can figure out which page relates to which record number? It's a report with header and details, so pagenumber is not recno() in that case.
>>
>>You could put a field with RECNO( "YourCursor" ) in the page footer. ISTR doing something like that a few times for report debugging purposes.
>
>I would see the record number on the report, but is there a way I can refer to it in code during the preview? I have a method on the previewform that would display information about the current record corresponding to the current page.

Wild speculation - maybe the preview process re-opens your report cursor and uses that for previewing? (in the same way the SQL engine re-opens tables during SELECT etc.) However, even if that's the case I don't know how you would find or access that extra cursor instance, or if it even exists after the rendering of the currently selected page is complete.
Regards. Al

"Violence is the last refuge of the incompetent." -- Isaac Asimov
"Never let your sense of morals prevent you from doing what is right." -- Isaac Asimov

Neither a despot, nor a doormat, be

Every app wants to be a database app when it grows up
Previous
Reply
Map
View

Click here to load this message in the networking platform