PrintControllerWithStatusDialog Class
Controls how a document is printed from a Windows Forms application.
Assembly: System.Windows.Forms (in System.Windows.Forms.dll)
This class implements a PrintController and adds a status dialog box. A print controller specifies how a PrintDocument is printed.
For a list of initial property values for an instance of the PrintControllerWithStatusDialog class, see the PrintControllerWithStatusDialog constructor.
For more information about printing with Windows Forms, see the System.Drawing.Printing namespace overview. If you want to print from a Windows Presentation Foundation application, see the System.Printing namespace.
The following code example shows how to create a new PrintController and assign it to the PrintController property. The example assumes that you have added the System.Drawing.Printing namespace to the class and that you have created a new instance of a PrintDocument as myDocumentPrinter.
Sub myPrint() If useMyPrintController = True Then myDocumentPrinter.PrintController = New myControllerImplementation() If wantsStatusDialog = True Then myDocumentPrinter.PrintController = _ New PrintControllerWithStatusDialog(myDocumentPrinter.PrintController) End If End If myDocumentPrinter.Print() End Sub
System.Drawing.Printing.PrintController
System.Windows.Forms.PrintControllerWithStatusDialog
Windows 7, Windows Vista, Windows XP SP2, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP Starter Edition, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003, Windows Server 2000 SP4, Windows Millennium Edition, Windows 98
The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.