共用方式為


How to: Display the PrintDialog Component

The PrintDialog component is the standard Windows print dialog box that many of your users will be familiar with. Because your users will be immediately comfortable with it, it would be beneficial for you to use the PrintDialog component.

To display the PrintDialog component

  • Call the ShowDialog method from within the code of your application.

    Once the component is shown, users will interact with it, setting the properties of the print job. These are saved in the PrinterSettings class (and the PageSettings class, if the user accesses the PageSetupDialog Component (Windows Forms) through the PrintDialog component) associated with that print job. You can then make calls to the properties they set to determine the specifics of the print job.

See Also

Tasks

How to: Create Standard Windows Forms Print Jobs
How to: Capture User Input from a PrintDialog at Run Time

Other Resources

PrintPreviewDialog Control (Windows Forms)
PrintDialog Component (Windows Forms)
Windows Forms Print Support
Windows Forms Controls