This documentation is archived and is not being maintained.

PrintDocument.DocumentName Property

Gets or sets the document name to display (for example, in a print status dialog box or printer queue) while printing the document.

[Visual Basic]
Public Property DocumentName As String
public string DocumentName {get; set;}
public: __property String* get_DocumentName();
public: __property void set_DocumentName(String*);
public function get DocumentName() : String;
public function set DocumentName(String);

Property Value

The document name to display while printing the document. The default is "document".


The DocumentName property does not specify the file to print. Rather, you specify the output to print by handling the PrintPage event. For an example of this, see the PrintDocument class overview.


Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

See Also

PrintDocument Class | PrintDocument Members | System.Drawing.Printing Namespace | PrintDocument | PrintPage