System.Windows.Forms.MouseEventArgs Class

Provides data for the Control.MouseUp, Control.MouseDown, and Control.MouseMove events.

See Also: MouseEventArgs Members

Syntax

[System.Runtime.InteropServices.ComVisible(true)]
public class MouseEventArgs : EventArgs

Remarks

The Control.MouseDown event occurs when the user presses the mouse button while the pointer is over a control. The Control.MouseUp event occurs when the user releases the mouse button while the pointer remains over the control. The Control.MouseMove event occurs when the user moves the mouse pointer over a control. A System.Windows.Forms.MouseEventArgs specifies which mouse button is pressed, how many times the mouse button was pressed and released, the coordinates of the mouse, and the amount the mouse wheel moved.

It is possible to receive a Control.MouseDown event without a corresponding Control.MouseUp, if the user switches focus to another application before releasing the mouse button.

These three events exist for the System.Windows.Forms.Control, System.Windows.Forms.AxHost, and System.Windows.Forms.NotifyIcon classes.

For information about the event model, see [<topic://cpconEventsDelegates>].

Requirements

Namespace: System.Windows.Forms
Assembly: System.Windows.Forms (in System.Windows.Forms.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0