Print Method
- Namespace
TXTextControl
- Package
TXTextControl.asTextControl. WinForms. SDK TXTextControl.from the private NuGet feed or Text Control Offline PackagesServer. dll
Description
Prints a Text Control document or a part of a document.
Syntax
Print(PrintDocument)
Prints the document using the printer settings of the specified PrintDocument.
public void Print(PrintDocument printDocument);Public Sub Print(printDocument As PrintDocument)| Parameter | Description | ||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| printDocument | Specifies an instance of the PrintDocument class. The following settings of the PrintDocument object are used:
|
Print(int, PrintPageEventArgs)
Prints a single page. This method can be called from the PrintPage event handler.
public void Print(int page, PrintPageEventArgs ppe);Public Sub Print(page As Integer, ppe As PrintPageEventArgs)| Parameter | Description |
|---|---|
| page | Specifies a page number to print. |
| ppe | Specifies the event arguments of the print document's PrintPage event. |
Examples
The following example prints the current document. The created object is then available to the surrounding document workflow.
textControl.Print(new System.Drawing.Printing.PrintDocument());
Console.WriteLine("Server Text Control is ready for use.");textControl.Print(New System.Drawing.Printing.PrintDocument())
Console.WriteLine("Server Text Control is ready for use.")