New to Telerik UI for ASP.NET AJAX? Start a free 30-day trial

The class holding all client-side events associated with the RadGrid control.

Definition

Namespace:Telerik.Web.UI

Assembly:Telerik.Web.UI.dll

Syntax:

C#
[TypeConverter(typeof(ExpandableObjectConverter))]
public class GridClientEvents : ObjectWithState

Inheritance: objectObjectWithStateGridClientEvents

Inherited Members object.ToString()object.Equals(object)object.Equals(object, object)object.ReferenceEquals(object, object)object.GetHashCode()object.GetType()object.MemberwiseClone()...

Constructors

C#
public GridClientEvents(StateBag OwnerStateBag)
Parameters:OwnerStateBagStateBag

Properties

Gets or sets the client-side event which will be fired after active row have changed.

C#
public virtual string OnActiveRowChanged { get; set; }
Property Value:

The active row changed event.

Gets or sets the client-side event which will be fired before a active row changes.

C#
public virtual string OnActiveRowChanging { get; set; }
Property Value:

The active row changing event.

Gets or sets the client-side event which will be fired when the EditMode is Batch and a cell value have been changed.

C#
public virtual string OnBatchEditCellValueChanged { get; set; }

Gets or sets the client-side event which will be fired when the EditMode is Batch and a cell value is changing. The event could be canceled.

C#
public virtual string OnBatchEditCellValueChanging { get; set; }

Gets or sets the client-side event which will be fired after a cell have been closed for edit.

C#
public virtual string OnBatchEditClosed { get; set; }

Gets or sets the client-side event which will be fired before closing a cell for edit.

C#
public virtual string OnBatchEditClosing { get; set; }

Gets or sets a client-side event which helps in custom implementation of the batch editing functionality. Gets the value from the cell which is positioned in the GridTemplateColumn.ItemTemplate.

C#
public virtual string OnBatchEditGetCellValue { get; set; }

Gets or sets a client-side event which helps in custom implementation of the batch editing functionality. Gets the value from the edit control which is positioned in the GridTemplateColumn.EditItemTemplate.

C#
public virtual string OnBatchEditGetEditorValue { get; set; }

Gets or sets the client-side event which will be fired after a cell have been opened for edit.

C#
public virtual string OnBatchEditOpened { get; set; }

Gets or sets the client-side event which will be fired before opening a cell for edit.

C#
public virtual string OnBatchEditOpening { get; set; }

Gets or sets a client-side event which helps in custom implementation of the batch editing functionality. Sets the value from the cell which is positioned in the GridTemplateColumn.ItemTemplate.

C#
public virtual string OnBatchEditSetCellValue { get; set; }

Gets or sets a client-side event which helps in custom implementation of the batch editing functionality. Sets the value from the edit control which is positioned in the GridTemplateColumn.EditItemTemplate.

C#
public virtual string OnBatchEditSetEditorValue { get; set; }

This client-side event is after a column cell is deselected client-side.

C#
public virtual string OnCellDeselected { get; set; }

This event is fired after a column cell has been deselected client-side.

Fired by

RadGrid

Arguments

N/A

Can be canceled

No

Examples

ascx/aspx

<ClientEvents OnCellDeselected="CellDeselected" ...

JavaScript

<script>

function CellDeselected()

{

alert("Cell deselected!");

}

</script>

This client-side event is before a column cell is deselected client-side.

C#
public virtual string OnCellDeselecting { get; set; }

This event is fired before a column cell has been deselected client-side.

Fired by

RadGrid

Arguments

N/A

Can be canceled

Yes

Examples

ascx/aspx

<ClientEvents OnCellDeselecting="CellDeselecting" ...

JavaScript

<script>

function CellDeselecting()

{

alert("Cell deselecting!");

}

</script>

This client-side event is after a column cell is selected client-side.

C#
public virtual string OnCellSelected { get; set; }

This event is fired after a column cell is selected client-side.

Fired by

RadGrid

Arguments

N/A

Can be canceled

No

Examples

ascx/aspx

<ClientEvents OnCellSelected="CellSelected" ...

JavaScript

<script>

function CellSelected()

{

alert("Cell selected!");

}

</script>

This client-side event is fired before a column cell is selected client-side.

C#
public virtual string OnCellSelecting { get; set; }

This event is fired before a column cell is selected client-side.

Fired by

RadGrid

Arguments

N/A

Can be canceled

Yes

Examples

ascx/aspx

<ClientEvents OnCellSelecting="CellSelecting" ...

JavaScript

<script>

function CellSelecting()

{

alert("Selecting column cell!");

}

</script>

Gets or sets the client-side event which will be fired when a colum have been clicked.

C#
public virtual string OnColumnClick { get; set; }
Property Value:

The on column click.

Gets or sets the client-side event which will be fired when a column is right clicked.

C#
public virtual string OnColumnContextMenu { get; set; }
Property Value:

The on column context menu.

This client-side event is fired after a column available at client-side is created.

C#
public virtual string OnColumnCreated { get; set; }

This event is fired after a column available at client-side is created.

Fired by

RadGridTable

Arguments

RadGridTableColumn object

Can be canceled

No
Examples

ascx/aspx

<ClientEvents OnColumnCreated="ColumnCreated" ...

JavaScript

<script>

function ColumnCreated(columnObject)

{

alert("Column with Index: " + columnObject.Index + " was created");

}

</script>

This client-side event is fired before column available at client-side creation.

C#
public virtual string OnColumnCreating { get; set; }

This event is fired before column available at client-side creation.

Fired by

RadGridTable

Arguments

N/A

Can be canceled

No

Examples

ascx/aspx

<ClientEvents OnColumnCreating="ColumnCreating" ...

JavaScript

<script>

function ColumnCreating()

{

alert("Creating column);

}

</script>

Gets or sets the client-side event which will be fired when a column have been double clicked.

C#
public virtual string OnColumnDblClick { get; set; }
Property Value:

The column double click event.

This client-side event is fired when a column object is destroyed.

C#
public virtual string OnColumnDestroying { get; set; }

This event is fired when a column object is destroyed.

Fired by

RadGridTable

Arguments

N/A

Can be canceled

No

Examples

ascx/aspx

<ClientEvents OnColumnDestroying="ColumnDestroying" ...

JavaScript

<script>

function ColumnDestroying()

{

alert("Destroing column with Index: " + this.Index);

}

</script>

Gets or sets the client-side event which is fired when a column have been hidden.

C#
public virtual string OnColumnHidden { get; set; }
Property Value:

The column hidden event.

Gets or sets the client-side event which is fired before a column have been hidden.

C#
public virtual string OnColumnHiding { get; set; }
Property Value:

The column hiding event.

Gets or sets the client-side event which will be fired when a mouse leaves a column element.

C#
public virtual string OnColumnMouseOut { get; set; }
Property Value:

The column mouse out event.

Gets or sets the client-side event which will be fired when a mouse hovers over a column element.

C#
public virtual string OnColumnMouseOver { get; set; }
Property Value:

The column mouse over event.

Gets or sets the client-side event which will be fired after a column have been moved to the left.

C#
public virtual string OnColumnMovedToLeft { get; set; }
Property Value:

The column moved to left event.

Gets or sets the client-side event which will be fired after a column have been moved to the right.

C#
public virtual string OnColumnMovedToRight { get; set; }
Property Value:

The column moved to right event.

Gets or sets the clint-side event which will be fired before a column have been moved to the left.

C#
public virtual string OnColumnMovingToLeft { get; set; }
Property Value:

The column moving to left event.

Gets or sets the clint-side event which will be fired before a column have been moved to the right.

C#
public virtual string OnColumnMovingToRight { get; set; }
Property Value:

The column moving to right event.

Gets or sets the client-side event which will be fired when a column have been resized.

C#
public virtual string OnColumnResized { get; set; }
Property Value:

The column resized event.

This client-side event is fired before a column is resized.

C#
public virtual string OnColumnResizing { get; set; }

This event is fired before a column is resized.

Fired by

RadGridTable

Arguments

columnIndex, columnWidth

Can be canceled

Yes, return false to cancel

Examples

ascx/aspx

<ClientEvents OnColumnResizing="ColumnResizing" ...

JavaScript

<script>

function ColumnResizing(columnIndex, columnWidth)

{

alert("Resizng column with Index: " + columnIndex + ", width: " + columnWidth);

}

OR

function ColumnResizing(columnIndex, columnWidth)

{

return false; //cancel ColumnResizing event

}

</script>

Gets or sets the client-side event which will be fired before a column have been shown.

C#
public virtual string OnColumnShowing { get; set; }
Property Value:

The column showing event.

Gets or sets the client-side event which will be fired when a column is shown.

C#
public virtual string OnColumnShown { get; set; }
Property Value:

The column shown event.

Gets or sets the client-side event which will be fired when a column have been swaped.

C#
public virtual string OnColumnSwapped { get; set; }
Property Value:

The column swapped event.

Gets or sets the client-side event which will be fired before a column have been swapped.

C#
public virtual string OnColumnSwapping { get; set; }
Property Value:

The column swapping event.

Gets or sets the client-side event which will be fired when a RadGrid command occurs.

C#
public virtual string OnCommand { get; set; }
Property Value:

The command event.

This event is fired when the grid request data using client-side data-binding.

C#
public virtual string OnDataBinding { get; set; }

This event is fired if request for data fails when using client-side data-binding.

C#
public virtual string OnDataBindingFailed { get; set; }

This event is fired when the grid client-side data-binding is finished.

C#
public virtual string OnDataBound { get; set; }

This event is fired when the grid client-side data is retrieved from the server.

C#
public virtual string OnDataSourceResolved { get; set; }

Gets or sets the client-side event which will be fired before the filter menu is shown.

C#
public virtual string OnFilterMenuShowing { get; set; }
Property Value:

The filter menu showing event.

This client-side event is fired after the grid is created.

C#
public virtual string OnGridCreated { get; set; }

This event is fired after the grid is created.

Fired by

RadGrid

Arguments

N/A

Can be canceled

No

Examples

ascx/aspx

<ClientEvents OnGridCreated="GridCreated" ...

JavaScript

<script>

function GridCreated()

{

alert("Grid with ClientID: " + this.ClientID + " was created");

}

</script>

This client-side event is fired before grid creation.

C#
public virtual string OnGridCreating { get; set; }

This event is fired before grid creation.

Fired by

RadGrid

Arguments

N/A

Can be canceled

No
Examples

ascx/aspx

<ClientEvents OnGridCreating="GridCreating" ...

JavaScript

<script>

function GridCreating()

{

alert("Creting grid with ClientID: " + this.ClientID);

}

</script>

This client-side event is fired when RadGrid object is destroyed, i.e. on each window.onunload

C#
public virtual string OnGridDestroying { get; set; }

This event is fired when RadGrid object is destroyed, i.e. on each window.onunload

Fired by

RadGrid

Arguments

N/A

Can be canceled

No
Examples

ascx/aspx

<ClientEvents OnGridCreating="GridDestroying" ...

JavaScript

<script>

function GridDestroying()

{

alert("Destroying grid with ClientID: " + this.ClientID);

}

</script>

Gets or sets the client-side event which is fired after a group have been collapsed.

C#
public virtual string OnGroupCollapsed { get; set; }
Property Value:

The group collapsed event.

Gets or sets the client-side event which is fired before a group is collapsed.

C#
public virtual string OnGroupCollapsing { get; set; }
Property Value:

The group collapsing event.

Gets or sets the client-side event which is fired after a group have been expanded.

C#
public virtual string OnGroupExpanded { get; set; }
Property Value:

The group expanded event.

Gets or sets the client-side event which is fired before a group is expanded.

C#
public virtual string OnGroupExpanding { get; set; }
Property Value:

The group expanding event.

Gets or sets the client-side event which is fired when RadGrid header RadContextMenu fires its 'Showing' event.

C#
public virtual string OnHeaderMenuShowing { get; set; }
Property Value:

The header menu showing event.

Gets or sets the client-side event which will be fired after a hierarchy have have been collapsed.

C#
public virtual string OnHierarchyCollapsed { get; set; }
Property Value:

The on hierarchy collapsed.

Gets or sets the client-side event which will be fired before a hierarchy is collapsed.

C#
public virtual string OnHierarchyCollapsing { get; set; }
Property Value:

The hierarchy collapsing event.

Gets or sets the client-side event which is fired after a hierarchy have been expanded.

C#
public virtual string OnHierarchyExpanded { get; set; }
Property Value:

The hierarchy expanded event.

Gets or sets the client-side event which is fired before a hierarchy is expanded.

C#
public virtual string OnHierarchyExpanding { get; set; }
Property Value:

The hierarchy expanding event.

Gets or sets the client-side event which will be fired when the grid is foused and a key is pressed.

C#
public virtual string OnKeyPress { get; set; }
Property Value:

The on key press.

This client-side event is fired after the MasterTableView is created.

C#
public virtual string OnMasterTableViewCreated { get; set; }

This event is fired after the MasterTableView is created.

Fired by

RadGrid

Arguments

N/A

Can be canceled

No

Examples

ascx/aspx

<ClientEvents OnMasterTableViewCreated="MasterTableViewCreated" ...

JavaScript

<script>

function MasterTableViewCreated()

{

alert("MasterTableView was created");

}

</script>

This client-side event is fired before the MasterTableView is created.

C#
public virtual string OnMasterTableViewCreating { get; set; }

This event is fired before the MasterTableView is created.

Fired by

RadGrid

Arguments

N/A

Can be canceled

No
Examples

ascx/aspx

<ClientEvents OnMasterTableViewCreating="MasterTableViewCreating" ...

JavaScript

<script>

function MasterTableViewCreating()

{

alert("Creating MasterTableView");

}

</script>

Gets or sets the client-side event which will fired before a popup is shown.

C#
public virtual string OnPopUpShowing { get; set; }
Property Value:

The pop up showing event.

Gets or sets the client-side event which will be fired when a row have been clicked.

C#
public virtual string OnRowClick { get; set; }
Property Value:

The row click event.

C#
public virtual string OnRowContextMenu { get; set; }

The client-side script for RadGrid.ClientSettings.ClientEvents.OnRowContextMenu kills any exceptions that occur in the event handler. This can make bugs hard to track down because it appears that nothing happens when actually the exception was killed before it becomes visible.

You can avoid this problem by putting a try/catch block around the event handler that sends an alert if an exception was thrown:

            RadGrid1.ClientSettings.ClientEvents.OnRowContextMenu = " try { ... my event handling code ... } catch (exp) { alert(exp.message); }";
                

Gets or sets the client-side event which will be fired when a row have been created.

C#
public virtual string OnRowCreated { get; set; }
Property Value:

The row created event.

Gets or sets the client-side event which will be fired before a row have been created.

C#
public virtual string OnRowCreating { get; set; }
Property Value:

The row creating event.

Gets or sets the client-side event which will be fired when a row is data bound. Note that the event could only be used in client-side data binding scenario.

C#
public virtual string OnRowDataBound { get; set; }
Property Value:

The row data bound event.

Gets or sets the client-side event which will be fired when a row have been double clicked.

C#
public virtual string OnRowDblClick { get; set; }
Property Value:

Thes row double click event.

Gets or sets the client-side event which will be fired after a row have been deleted with GridClientDeleteColumn or deleteItem method.

C#
public virtual string OnRowDeleted { get; set; }
Property Value:

The row deleted event.

Gets or sets the client-side event which will be fired before row have been deleted with GridClientDeleteColumn or deleteItem method.

C#
public virtual string OnRowDeleting { get; set; }
Property Value:

The row deleting event.

Gets or sets the client-side event which will be fired when a row have been deselected.

C#
public virtual string OnRowDeselected { get; set; }
Property Value:

The row deselected event.

Gets or sets the client-side event which will be fired before a row is deselected.

C#
public virtual string OnRowDeselecting { get; set; }
Property Value:

The row deselecting event.

Gets or sets the client-side event which will be fired when a row have been destroyed.

C#
public virtual string OnRowDestroying { get; set; }
Property Value:

The row destroying event.

Gets or sets the client-side event which will be fired when a RadGrid row is being dragged.

C#
public virtual string OnRowDragging { get; set; }
Property Value:

The row dragging event.

Gets or sets the client-side event which will be fired when a RadGrid row drag starts.

C#
public virtual string OnRowDragStarted { get; set; }
Property Value:

The row drag started event.

Gets or sets the client-side event which is fired when a RadGrid row is dropped.

C#
public virtual string OnRowDropped { get; set; }
Property Value:

The on row dropped event.

Gets or sets the client-side event which is fired when a RadGrid row is dropping.

C#
public virtual string OnRowDropping { get; set; }
Property Value:

The on row dropping event.

Gets or sets the client-side event which will be fired when a row have been hidden.

C#
public virtual string OnRowHidden { get; set; }
Property Value:

The on row hidden.

Gets or sets the client-side event which will be fired before a row is hidden.

C#
public virtual string OnRowHiding { get; set; }
Property Value:

The row hiding event.

Gets or sets the client-side event which will be fired when a mouse leaves a row element.

C#
public virtual string OnRowMouseOut { get; set; }
Property Value:

The row mouse out event.

Gets or sets the client-side event which will be fired when a mouse hovers over a row element.

C#
public virtual string OnRowMouseOver { get; set; }
Property Value:

The row mouse over event.

Gets or sets the client-side event which is fired when a row have been resized.

C#
public virtual string OnRowResized { get; set; }
Property Value:

The row resized event.

Gets or sets the client-side event which will be fired before a row have been resized.

C#
public virtual string OnRowResizing { get; set; }
Property Value:

The on row resizing.

Gets or sets the client-side event which will be fired when a row have been selected.

C#
public virtual string OnRowSelected { get; set; }
Property Value:

The row selected event.

Gets or sets the client-side event which will be fired before a row is selected.

C#
public virtual string OnRowSelecting { get; set; }
Property Value:

The row selecting event.

Gets or sets the client-side event which will be fired before a row is shown.

C#
public virtual string OnRowShowing { get; set; }
Property Value:

The row showing event.

Gets or sets the client-side event which will be fired when a row have been shown.

C#
public virtual string OnRowShown { get; set; }
Property Value:

The row shown event.

Gets or sets the client-side event which will be fired when RadGrid is scrolled.

C#
public virtual string OnScroll { get; set; }
Property Value:

The on scroll.

This client-side event is fired after the table is created.

C#
public virtual string OnTableCreated { get; set; }

This event is fired after the table is created.

Fired by

RadGrid

Arguments

RadGridTable Object

Can be canceled

No
Examples

ascx/aspx

<ClientEvents OnTableCreated="TableCreated" ...

JavaScript

<script>

function TableCreated(tableObject)

{

alert("DetailTable with ClientID: " + tableObject.ClientID + " was created");

}

</script>

This client-side event is fired before table creation.

C#
public virtual string OnTableCreating { get; set; }

This event is fired before table creation.

Fired by

RadGrid

Arguments

N/A

Can be canceled

No

Examples

ascx/aspx

<ClientEvents OnTableCreating="TableCreating" ...

JavaScript

<script>

function TableCreating()

{

alert("Creating DetailTable");

}

</script>

This client-side event is fired when table object is destroyed.

C#
public virtual string OnTableDestroying { get; set; }

This event is fired when table object is destroyed.

Fired by

RadGrid

Arguments

N/A

Can be canceled

No

Examples

ascx/aspx

<ClientEvents OnTableDestroying="TableDestroying" ...

JavaScript

<script>

function TableDestroying()

{

alert("Destroing DetailTable with ClientID: " + this.ClientID);

}

</script>

Gets or sets the client-side event which will be fired when a user performs an action to the RadGrid control which will cause a postback or change the data. The event could be used to popup a dialog and verify if the user is certain in performing the current action.

C#
public virtual string OnUserAction { get; set; }
In this article
DefinitionConstructorsGridClientEvents(StateBag)PropertiesOnActiveRowChangedOnActiveRowChangingOnBatchEditCellValueChangedOnBatchEditCellValueChangingOnBatchEditClosedOnBatchEditClosingOnBatchEditGetCellValueOnBatchEditGetEditorValueOnBatchEditOpenedOnBatchEditOpeningOnBatchEditSetCellValueOnBatchEditSetEditorValueOnCellDeselectedOnCellDeselectingOnCellSelectedOnCellSelectingOnColumnClickOnColumnContextMenuOnColumnCreatedOnColumnCreatingOnColumnDblClickOnColumnDestroyingOnColumnHiddenOnColumnHidingOnColumnMouseOutOnColumnMouseOverOnColumnMovedToLeftOnColumnMovedToRightOnColumnMovingToLeftOnColumnMovingToRightOnColumnResizedOnColumnResizingOnColumnShowingOnColumnShownOnColumnSwappedOnColumnSwappingOnCommandOnDataBindingOnDataBindingFailedOnDataBoundOnDataSourceResolvedOnFilterMenuShowingOnGridCreatedOnGridCreatingOnGridDestroyingOnGroupCollapsedOnGroupCollapsingOnGroupExpandedOnGroupExpandingOnHeaderMenuShowingOnHierarchyCollapsedOnHierarchyCollapsingOnHierarchyExpandedOnHierarchyExpandingOnKeyPressOnMasterTableViewCreatedOnMasterTableViewCreatingOnPopUpShowingOnRowClickOnRowContextMenuOnRowCreatedOnRowCreatingOnRowDataBoundOnRowDblClickOnRowDeletedOnRowDeletingOnRowDeselectedOnRowDeselectingOnRowDestroyingOnRowDraggingOnRowDragStartedOnRowDroppedOnRowDroppingOnRowHiddenOnRowHidingOnRowMouseOutOnRowMouseOverOnRowResizedOnRowResizingOnRowSelectedOnRowSelectingOnRowShowingOnRowShownOnScrollOnTableCreatedOnTableCreatingOnTableDestroyingOnUserAction
Not finding the help you need?
Contact Support