Control.OnPrint(PaintEventArgs) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Raises the Paint event.
protected:
virtual void OnPrint(System::Windows::Forms::PaintEventArgs ^ e);
protected virtual void OnPrint (System.Windows.Forms.PaintEventArgs e);
abstract member OnPrint : System.Windows.Forms.PaintEventArgs -> unit
override this.OnPrint : System.Windows.Forms.PaintEventArgs -> unit
Protected Overridable Sub OnPrint (e As PaintEventArgs)
Parameters
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
Collaborate with us on GitHub
The source for this content can be found on GitHub, where you can also create and review issues and pull requests. For more information, see our contributor guide.