Control.OnPrint(PaintEventArgs) Method

Definition

Raises the Paint event.

C#
protected virtual void OnPrint(System.Windows.Forms.PaintEventArgs e);

Parameters

e
PaintEventArgs

A PaintEventArgs that contains the event data.

Exceptions

The e parameter is null.

Remarks

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

Applies to

See also