- - * - WhiteUnicorn - * - -




* #WhiteUnicorn/ StartPage/ Documentation/DelphiFAQ >


Frequently Asked Questions

Using an instance of TPrinter

Question:

When I create an instance of TPrinter using TPrinter.Create, I get an exception. How can I get around this?

Answer:

There is no need to create an instance of TPrinter 
using TPrinter.Create, as an instance of TPrinter (called Printer) 
is automatically created when you use the Printers unit.

Example:

uses Printers;

procedure TForm1.Button1Click(Sender: TObject);
begin
   Printer.BeginDoc;
   Printer.Canvas.TextOut(100, 100, 'Hello World!');
   Printer.EndDoc;
end;



* #WhiteUnicorn/ StartPage/ Documentation/DelphiFAQ >



- - * - Anastasija aka WhiteUnicorn - * - - LJLiveJournal
PFPhotoFile