Lightening


in VFP9, I tried to use

use my table

report form test noconsole preview

  "Page " + TRANS(_PAGENO) + " of " + TRANS( _PAGETOTAL)
But the _pagetotal value is always 1 although the report contains 4 pages. 
What is that 



Re: Why _pageTotal always shows 1 ???

dni


In my reports I am using:

Label1 Field1 Label 2 Fileld2

where: Label1 = "Page"

Label2="/"

FIELD1 has expression : _pageno (no trans)

FIELD2 has expression: _pagetotal (no trans)

I do not know why but I don't have any problem and it is working fine.





Re: Why _pageTotal always shows 1 ???

Lightening

Thank you, but

It shows the same even if I removed "Trans"

"Page " , _PAGENO , "of", _Pagetotal






Re: Why _pageTotal always shows 1 ???

dni

There were labels and fields that I did put direct in report designer. You need to run once the report to have a value for _PageTotal:

REPORT FORM <ReportName> NOCONSOLE

After that you may check

"Page " , _PAGENO , "of", _Pagetotal

or with TRANS().






Re: Why _pageTotal always shows 1 ???

Lightening

I know why now.

I had a group. and set the "Group on New page no. 1"

Each group has different length and even if you have multiple pages for the group, you still have 1 _PageTotal.

It might be a VFP9 bug. But unfortunately, we can hardly get support from Microsoft now.





Re: Why _pageTotal always shows 1 ???

dni

You may try:

TotalPages = 0
REPORT FORM <ReportName> TO tmp.txt NOCONSOLE
TotalPages=_pageno
ERASE tmp.txt

TotalPages should have the right total number of pages.






Re: Why _pageTotal always shows 1 ???

Lightening

i know this. But it will slow down the process a lot.

We have almost 2000 records to print. Each record has a group and different total pages.

Thank you for your help anyway.





Re: Why _pageTotal always shows 1 ???

Tamar E. Granor

Actually, it's important to submit any bugs you know of now, so they can be considered for SP2. After that, only really serious bugs (data-eaters, for the most part) are likely to be fixed. But right now is our chance to get really broken things fixed.

Tamar




Re: Why _pageTotal always shows 1 ???

Lightening

Tamar,

Could you help contact Microsoft for this problem

I raised another question about the image control in the report. It seems to remain unresolved, too.

Thank you!





Re: Why _pageTotal always shows 1 ???

Tamar E. Granor

To get an error report to the team, use the Connect website:

http://connect.microsoft.com/feedback/default.aspx SiteID=210

That's the official place to report problems.

Tamar