Prints a page of text on the default printer. The number is specified through PageNumber.
TXTextControl.PrintPage PageNumber
Parameter | Description | |
PageNumber |
Specifies the number of the page to print. The first page has the number 1. |
This method has no return value.
Prior to using this method the Text Control's output device must be selected using the PrintDevice property.
PageNumber | Integer |
This Basic example shows how to print the contents of a Text Control on the default printer:
Sub mnuFile_Print_Click () Dim wPages, No Printer.Print wPages = TXTextControl1.CurrentPages For No = 1 To wPages TXTextControl1.PrintDevice = Printer.hDC TXTextControl1.PrintPage No Printer.NewPage Next No Printer.EndDoc End Sub
<< TXTextControl.PrintOffset Property | >> TXTextControl.PrintZoom Property