PrinterSettings.PrintToFile
This property is used by the PrintDialog when the user selects the Print
to file option. In such a case, the output port is set to "FILE",
causing the Windows printing subsystem to prompt the user for a file
name when the PrintDocument.Print method is called.
Note: The PrinterSettings.PrintToFile property can only be set by the
System.Windows.Forms.Printing.PrintDialog class. The Print to file
option only appears on the System.Windows.Forms.Printing.PrintDialog
when the System.Windows.Forms.Printing.PrintDialog.AllowPri ntToFile
property is set to true. For more information, see the KB article
"'PrintDocument Class' Does Not Implement The PrintToFile Feature
(820644)" on Microsoft TechNet, at
http://www.microsoft.com/technet .
ms-help://MS.VSCC.2003/MS.MSDNQTR.2003OCT.1033/cpref/html/frlrfsystemdrawingprintingprintersettingsclassprin ttofiletopic.htm
ms-help://MS.VSCC.2003/MS.MSDNQTR.2003OCT.1033/cpref/html/frlrfsystemdrawingprintingprintersettingsmembersto pic.htm
an*******@discussions.microsoft.com wrote:
My question is still open:
How can I redirect a print job to a file? There is a
checkbox in the print dialog, but I would like to do it
in code indicating a filename.
Thanks
Bruno Hardmeier
-----Original Message-----
* "Perilmind" <an*******@discussions.microsoft.com>
scripsit:
You can use a fprintf typing in the file buffer and
the
filename.
That's a function of the C runtime...
;-)
--
Herfried K. Wagner
MVP · VB Classic, VB.NET
<http://www.mvps.org/dotnet>
<http://www.plig.net/nnq/nquote.html>
.