New to Telerik UI for ASP.NET AJAXStart a free 30-day trial

get_clientDataKeyNames()

One-dimensional array which holds the key fields set through the ClientDataKeyNames property of GridTableView on the server. To extract the key values you can use the eventArgs.getDataKeyValue() inside any row-related client event handler of RadGrid.

You should set ClientDataKeyNames server-side in order to access the key values client-side!

Example:

ASP.NET
	<ClientSettings>
	  <ClientEvents OnHierarchyExpanded="HierarchyExpanded" />
	</ClientSettings>
JavaScript
	function HierarchyExpanded(sender, args)
	{  
	    var firstClientDataKeyName = args.get_tableView().get_clientDataKeyNames()[0];
	    alert("Item with " + firstClientDataKeyName + ":'" + args.getDataKeyValue(firstClientDataKeyName) + "' expanded.");
	}
Not finding the help you need?
Contact Support