[Overview][Types][Classes][Variables][Index] | Reference for unit 'Printers' (#lcl)

# TPrinter.DoInitialization

Performs initializations after the list of Printers has been populated.

## Declaration

Source position: printers.pas line 278

`protected procedure TPrinter.DoInitialization; virtual;`

## Description

DoInitialization is a method used to initialize the class instance after the list of supported Printers has been retrieved. DoInitialization has an empty implementation in TPrinter, and must overridden in a descendent class to implement the functionality.

DoInitialization is called from the GetPrinters method, and occurs only once when the PrinterFlags does NOT include the values pfPrintersValid and pfDestroying. When called, the DoEnumPrinters method has successfully completed and the default printer has been selected using the SelectCurrentPrinterOrDefault method.

## See also

TPrinter.Printers |  | Contains the names for devices that can be selected for printing.
TPrinter.Printers |  | Contains the names for devices that can be selected for printing.
TPrinter.PrinterFlags |  | Status flags currently enabled for the print device.
TPrinter.DoEnumPrinters |  | Performs actions needed to populate the specified list with available printers.
TPrinter.SelectCurrentPrinterOrDefault |  | Selects the default printer when a printer has not been selected.
TPrinterFlags |  | Represents status flag values used for printer devices.