PrintDocument Members

Defines a reusable object that sends output to a printer, when printing from a Windows Forms application.

The PrintDocument type exposes the following members.

  NameDescription
Public method PrintDocument Initializes a new instance of the PrintDocument class.
Top

  NameDescription
Public method CreateObjRef Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from MarshalByRefObject.)
Public method Dispose Overloaded. Releases the resources used by the Component.
Public method Equals Determines whether the specified Object is equal to the current Object. (Inherited from Object.)
Protected method Finalize Releases unmanaged resources and performs other cleanup operations before the Component is reclaimed by garbage collection. (Inherited from Component.)
Public method GetHashCode Serves as a hash function for a particular type. (Inherited from Object.)
Public method GetLifetimeService Retrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from MarshalByRefObject.)
Protected method GetService Returns an object that represents a service provided by the Component or by its Container. (Inherited from Component.)
Public method GetType Gets the type of the current instance. (Inherited from Object.)
Public method InitializeLifetimeService Obtains a lifetime service object to control the lifetime policy for this instance. (Inherited from MarshalByRefObject.)
Protected method MemberwiseClone Overloaded.
Protected method OnBeginPrint Raises the BeginPrint event. It is called after the Print method is called and before the first page of the document prints.
Protected method OnEndPrint Raises the EndPrint event. It is called when the last page of the document has printed.
Protected method OnPrintPage Raises the PrintPage event. It is called before a page prints.
Protected method OnQueryPageSettings Raises the QueryPageSettings event. It is called immediately before each PrintPage event.
Public method Print Starts the document's printing process.
Public method ToString Infrastructure. Provides information about the print document, in string form. (Overrides Component.ToString().)
Top

  NameDescription
Protected property CanRaiseEvents Gets a value indicating whether the component can raise an event. (Inherited from Component.)
Public property Container Gets the IContainer that contains the Component. (Inherited from Component.)
Public property DefaultPageSettings Gets or sets page settings that are used as defaults for all pages to be printed.
Protected property DesignMode Gets a value that indicates whether the Component is currently in design mode. (Inherited from Component.)
Public property DocumentName Gets or sets the document name to display (for example, in a print status dialog box or printer queue) while printing the document.
Protected property Events Gets the list of event handlers that are attached to this Component. (Inherited from Component.)
Public property OriginAtMargins Gets or sets a value indicating whether the position of a graphics object associated with a page is located just inside the user-specified margins or at the top-left corner of the printable area of the page.
Public property PrintController Gets or sets the print controller that guides the printing process.
Public property PrinterSettings Gets or sets the printer that prints the document.
Public property Site Gets or sets the ISite of the Component. (Inherited from Component.)
Top

  NameDescription
Public event BeginPrint Occurs when the Print method is called and before the first page of the document prints.
Public event Disposed Occurs when the component is disposed by a call to the Dispose method. (Inherited from Component.)
Public event EndPrint Occurs when the last page of the document has printed.
Public event PrintPage Occurs when the output to print for the current page is needed.
Public event QueryPageSettings Occurs immediately before each PrintPage event.
Top
Was this page helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft