Mark,
There have been a lot of threads on this topic, including another running today. You only need one report, but you need to 'print' it twice. The first time you send it to a file. Store the _pageno value to a variable, and use it the SECOND time as your "X" in "Page 1 of X".
It's slow if you have huge reports, but is the only way to be confident of getting the correct number of pages. Note that doing a PREVIEW doesn't always give you the correct number. Windows occasionally hiccups and the Preview is not always identical to the printed result.
HTH
Barbara
>I'm trying to print on each of my pages in a VFP report, "Page 1 of X", "Page 2 of X", etc...
>
>Anyone know how to get the value of "X" as being the total number of pages?
>
>TIA!
>
>Mark