Edit this page


Property that returns a collection of GridDataItems which the respective GridTableView holds.Generally used when there is a need to access the grid data on the client.


<telerik:RadGrid RenderMode="Lightweight" ID="RadGrid1" OnNeedDataSource="RadGrid1_NeedDataSource" runat="server" >
    <MasterTableView AutoGenerateColumns="false">
            <telerik:GridBoundColumn UniqueName="CustomerID" DataField="CustomerID" HeaderText="Customer ID">
            <telerik:GridBoundColumn UniqueName="ContactName" DataField="ContactName" HeaderText="Contact Name">
        <ClientEvents OnGridCreated="gridCreated" />
function gridCreated(sender,args) {
     var dataItems = $find('<%=RadGrid1.ClientID%>').get_masterTableView().get_dataItems();
     for (var i = 0; i < dataItems.length; i++) {
         var customerId = dataItems[i].get_cell("CustomerID").innerHTML,
             contactName = dataItems[i].get_cell("ContactName").innerHTML;
         alert('The customer with ID ' + customerId + ' has contacted ' + contactName);
Is this article helpful? No Yes
Thank you for your feedback!

Give article feedback

Tell us how we can improve this article