NewPage and ShowBand at the same time?
On Report I have this bands:
PageHeader
MasterData
DetailHeader
DetailData
DetailFooter
PageFoter
In MaserData I have only one record, in DetailData more then 20 records
I need to set insert pagebreak with DetailHeader on new page when comes DetailData record number 6. I try with OnBeforePrint on DetailData:
Otzi
PageHeader
MasterData
DetailHeader
DetailData
DetailFooter
PageFoter
In MaserData I have only one record, in DetailData more then 20 records
I need to set insert pagebreak with DetailHeader on new page when comes DetailData record number 6. I try with OnBeforePrint on DetailData:
if [LINE#] = 6 then begin
 NewPage;
 ShowBand(DetailHeader);
end;
But this shows band DetailHeader on previous page and 6th record on new page. Is this OK? I expected DetailHeader on new page.Otzi
Comments
add a boolean variable set it's value to false at start of report, in obp of master set it to true, reset it to false in a detail footer.
test it in obp of pageheader and if true try calling showband there.
I usually add a child band attached to the pageheader which duplicates the header I want and just control it's visibility as required.
regards