System.Windows.Forms.UpDownBase.OnMouseWheel Method

Raises the Control.MouseWheel event.

Syntax

protected override void OnMouseWheel (MouseEventArgs e)

Parameters

e
A System.Windows.Forms.MouseEventArgs that contains the event data.

Remarks

If the spin box (also known as an up-down control) has focus when this event occurs, the direction the user scrolled the mouse wheel is determined, and either the UpDownBase.UpButton or UpDownBase.DownButton method is called.

Raising an event invokes the event handler through a delegate. For more information, see Raising an Event.

The UpDownBase.OnMouseWheel(MouseEventArgs) method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.

Requirements

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