Bewerken

Delen via


DataGridView.OnScroll(ScrollEventArgs) Method

Definition

Raises the Scroll event.

protected:
 virtual void OnScroll(System::Windows::Forms::ScrollEventArgs ^ e);
protected virtual void OnScroll (System.Windows.Forms.ScrollEventArgs e);
abstract member OnScroll : System.Windows.Forms.ScrollEventArgs -> unit
override this.OnScroll : System.Windows.Forms.ScrollEventArgs -> unit
Protected Overridable Sub OnScroll (e As ScrollEventArgs)

Parameters

e
ScrollEventArgs

A ScrollEventArgs that contains the event data.

Remarks

Raising an event invokes the event handler through a delegate. For more information, see Handling and Raising Events.

The OnScroll 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.

Notes to Inheritors

When overriding OnScroll(ScrollEventArgs) in a derived class, be sure to call the base class' OnScroll(ScrollEventArgs) method so that registered delegates receive the event.

Applies to

See also