TppPage.AddDrawCommand: Cannot add more than one draw outline command per page.
I added a Cover Page subreport to the TitleBand and now I am getting
this message. Any ideas?
I only get the error after I do something in print preview it seems. If
I click print upon entering print preview it seems to print fine but if
I change to a different page or print another copy it happens. If I
close the error dialog and click Print again, it prints just fine.
I have not added any DrawCommand code just added the sub report for the
cover page.
Mark Greenhaw
One Domain, Inc.
this message. Any ideas?
I only get the error after I do something in print preview it seems. If
I click print upon entering print preview it seems to print fine but if
I change to a different page or print another copy it happens. If I
close the error dialog and click Print again, it prints just fine.
I have not added any DrawCommand code just added the sub report for the
cover page.
Mark Greenhaw
One Domain, Inc.
This discussion has been closed.
Comments
Which version of ReportBuilder are you using? What type of subreport did
you add to the title? Are you doing this in code or at design time?
--
Regards,
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Added a sub report to the TitleBand of one of my other reports and named
it ppsrCoverPage.
Added a variable to the Private variables called CoverPage and make it
boolean
Add the following code to the main procedure on the report form before
the call to rbMain.Print. ...
// Create cover page
CoverPage := False;
if dmCvHeaderInfo.CoverPageRTF <> '' then
begin
ppTitleBand1.Visible := True;
ppsrCoverPage.Visible := True;
frmRbCoverPage := TfrmRbCoverPage.Create (nil);
CoverPage := True;
end
else
begin
ppTitleBand1.Visible := False;
ppFooterBand1.PrintOnFirstPage := True;
end;
// end cover page creation
Add this to rbMainBeforePrint and modify accordingly
if CoverPage then
begin
ppsrCoverPage.SetReportProperty(frmRbCoverPage.rbMain);
SetupCoverPage(rbMain.PrinterSetup.Orientation,
rbMain.PrinterSetup.MarginTop,
rbMainNHR.PrinterSetup.MarginBottom,
rbMain.PrinterSetup.MarginLeft, rbMain.PrinterSetup.MarginRight);
end;
Add this section to the FormDestroy event for the calling form...
if CoverPage and (frmRbCoverPage <> nil) then
begin
ppsrCoverPage.SetReportProperty(nil);
FreeAndNil(frmRbCoverPage);
end;
Could it be because both reports called the actual report component
"rbMain"?
with it. I changed the name of the one on the CoverPage report and still
get the same error.
Which version of ReportBuilder are you using? What type of Subreport are
you using in the title?
--
Regards,
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com