Was this page helpful?
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

Control.OnPrint Method (PaintEventArgs)


Raises the Paint event.

Namespace:   System.Windows.Forms
Assembly:  System.Windows.Forms (in System.Windows.Forms.dll)

protected virtual void OnPrint(
	PaintEventArgs e


Type: System.Windows.Forms.PaintEventArgs

A PaintEventArgs that contains the event data.

Exception Condition

The e parameter is null.

If the UserPaint bit of the ControlStyles is set, you can override OnPrint to do layered painting. See SetStyle for more information.

.NET Framework
Available since 2.0
Return to top
Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
© 2015 Microsoft