The problem as I see it - is how can VFP predict full length of the report at the start? Many things are dependent on the data - even to the point of things like starting a new grouping on a new page - which could cause a gap at a bottom of a page. Unless, of course, VFP can internally run the report without you seeing it - in like a 1st pass - so that it can properly determine total # of pages! Anyway - those are my thoughts on the matter...
Although - truthfully - I have even done much in the way of reports for years. The one system I worked on here had "reports" - but, they were ALL just Excel files. The other system I still currently support - it has reports - but, they just work and have not needed ANY Modifications in the past nearly 2 years since I have been support this system.
Regards, Kurt Wendt Senior Systems Analyst
Tel. +1-212-747-9100 www.GlobeTax.com
-----Original Message----- From: ProfoxTech [mailto:profoxtech-bounces@leafe.com] On Behalf Of Richard Kaye Sent: Monday, March 27, 2017 1:24 PM To: profoxtech@leafe.com Subject: RE: VFP9SP2 report error with _pagetotal variable
[Page ]+ALLTRIM(TRANSFORM(_pageno))+IIF(_pagetotal>1,[ of ]+ALLTRIM(TRANSFORM(_pagetotal)),[])
This is the expression I use. I can't recall seeing it misbehave.
--
rk -----Original Message----- From: ProfoxTech [mailto:profoxtech-bounces@leafe.com] On Behalf Of Ted Roche Sent: Monday, March 27, 2017 1:21 PM To: profoxtech@leafe.com Subject: Re: VFP9SP2 report error with _pagetotal variable
The MSDN suggests your string to print it is too complicated to parse and recognize that _PAGETOTAL is being invoked, and to force VFP to run the report in two-pass mode. The IIF() near the end of the article should resolve:
https://msdn.microsoft.com/en-us/library/aa977060(v=vs.71).aspx
HWP's What's New in VFP8 also has some good suggestions.
On Mon, Mar 27, 2017 at 1:10 PM, mbsoftwaresolutions@mbsoftwaresolutions.com wrote:
On 2017-03-27 13:10, Richard Kaye wrote:
How do you have REPORTBEHAVIOR set?
I tried it with 80 and 90, both. Same problem.
[excessive quoting removed by server]