thank you for your reply. I have a button in my preview form that does the following:
procedure TFormPrintPreview.BtnPrint1Click(Sender: TObject); begin (ppViewer.Report As TppReport).PageLimit := ppViewer.CurrentPage.PageNo; (ppViewer.Report As TppReport).ShowPrintDialog := False; ppViewer.Print; (ppViewer.Report As TppReport).PageLimit := 0; end;
But it seems printing pages 1 to ppViewer.CurrentPage.PageNo. I only want to print the page I currently see; like when you say print and choose the "only current page" in the Printer dialogue.
You'll need to edit the page list that is going to be generated to the printer. There is a demo of this in your installed demos main report directory. It is #124.
Comments
Cheers,
Jim Bennett
Digital Metaphors
http://www.digital-metaphors.com
info@digital-metaphors.com
thank you for your reply.
I have a button in my preview form that does the following:
procedure TFormPrintPreview.BtnPrint1Click(Sender: TObject);
begin
(ppViewer.Report As TppReport).PageLimit := ppViewer.CurrentPage.PageNo;
(ppViewer.Report As TppReport).ShowPrintDialog := False;
ppViewer.Print;
(ppViewer.Report As TppReport).PageLimit := 0;
end;
But it seems printing pages 1 to ppViewer.CurrentPage.PageNo.
I only want to print the page I currently see; like when you say print and
choose the "only current page" in the Printer dialogue.
Stephan
printer. There is a demo of this in your installed demos main report
directory. It is #124.
Cheers,
Jim Bennett
Digital Metaphors
http://www.digital-metaphors.com
info@digital-metaphors.com