ReportViewer.PrintingBegin Event

 

Occurs when the user clicks the Print button in the Print dialog box.

Namespace:   Microsoft.Reporting.WinForms
Assembly:  Microsoft.ReportViewer.WinForms (in Microsoft.ReportViewer.WinForms.dll)

Syntax

public event ReportPrintEventHandler PrintingBegin
public:
event ReportPrintEventHandler^ PrintingBegin {
    void add(ReportPrintEventHandler^ value);
    void remove(ReportPrintEventHandler^ value);
}
member PrintingBegin : IEvent<ReportPrintEventHandler,
    ReportPrintEventArgs>
Public Event PrintingBegin As ReportPrintEventHandler

Remarks

This event can occur when the Print dialog box is launched by the PrintDialog method or by the user clicking the Print button in the toolbar. Information about this event is passed in a ReportPrintEventArgs object to the ReportPrintEventHandler delegate, which handles the event.

The event arguments contain the printer settings the user selects in the Print dialog box. If this event is not cancelled, the printer settings are saved into the PrinterSettings property. If this event is cancelled, the Printing dialog box is not displayed, the report is not printed, and the printer settings are not saved.

For more information about handling events, see NIB: Consuming Events.

See Also

ReportViewer Class
Microsoft.Reporting.WinForms Namespace

Return to top