Export (0) Print
Expand All

DataGrid Events

The events of the DataGrid class are listed here. For a complete list of DataGrid class members, see the DataGrid Members topic.

Public Events

public eventCancelCommand Occurs when the Cancel button is clicked for an item in the DataGrid control.
public eventDataBinding (inherited from Control) Occurs when the server control binds to a data source.
public eventDeleteCommand Occurs when the Delete button is clicked for an item in the DataGrid control.
public eventDisposed (inherited from Control) Occurs when a server control is released from memory, which is the last stage of the server control lifecycle when an ASP.NET page is requested.
public eventEditCommand Occurs when the Edit button is clicked for an item in the DataGrid control.
public eventInit (inherited from Control) Occurs when the server control is initialized, which is the first step in the its lifecycle.
public eventItemCommand Occurs when any button is clicked in the DataGrid control.
public eventItemCreated Occurs on the server when an item in the DataGrid control is created.
public eventItemDataBound Occurs after an item is data bound to the DataGrid control.
public eventLoad (inherited from Control) Occurs when the server control is loaded into the Page object.
public eventPageIndexChanged Occurs when one of the page selection elements is clicked.
public eventPreRender (inherited from Control) Occurs when the server control is about to render to its containing Page object.
public eventSelectedIndexChanged (inherited from BaseDataList) Occurs when a different item is selected in a data listing control between posts to the server.
public eventSortCommand Occurs when a column is sorted.
public eventUnload (inherited from Control) Occurs when the server control is unloaded from memory.
public eventUpdateCommand Occurs when the Update button is clicked for an item in the DataGrid control.

See Also

DataGrid Class | System.Web.UI.WebControls Namespace

Show:
© 2014 Microsoft