edhasted
asked on
Delphi 5 - How to Send a FORM FEED Command
I am using Delphi 5 (still) and just finishing off an application.
It would be REALLY useful if I could click on a button to send a Form Feed to the default printer.
Can someone tell me what the correct lines to insert are?
The rest of the reports are, suprisingly, generated by QReports :-).
With thanks,
Ed
It would be REALLY useful if I could click on a button to send a Form Feed to the default printer.
Can someone tell me what the correct lines to insert are?
The rest of the reports are, suprisingly, generated by QReports :-).
With thanks,
Ed
ASKER
With the formfeed.dpr function I was uncertain how to imbed it into my program and then call it - exuse my naievity.
With the Torry example what happens if it's not LPT1? Is it possible to get it to send to the defualt printer?
Ed
With the Torry example what happens if it's not LPT1? Is it possible to get it to send to the defualt printer?
Ed
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Where does Printer. come from?
Delphi generates unidentfied Identifer when I try this.
There doesn't appear to be a Printer. drop in or am I missing something fundametnal.
Yours,
Ed
Delphi generates unidentfied Identifer when I try this.
There doesn't appear to be a Printer. drop in or am I missing something fundametnal.
Yours,
Ed
ASKER
Sorted, put the Printers unit and and prefixed the syntax so it reads:
begin
Printers.Printer.BeginDoc;
Printers.Printer.EndDoc;
end;
This is universally simple - sends to the defaul printer and wonderfully short.
This is the quickest and most efficient of the solution provided.
With many thanks,
Ed Hasted
begin
Printers.Printer.BeginDoc;
Printers.Printer.EndDoc;
end;
This is universally simple - sends to the defaul printer and wonderfully short.
This is the quickest and most efficient of the solution provided.
With many thanks,
Ed Hasted
Maybe this sample code at:
http://www.wilsonc.demon.co.uk/Delphi3Components/formfeed.dpr