<ej:Grid ID="Grid1" runat="server" AllowPaging="True" OnServerRowSelected="Grid1_ServerRowSelected">
<Columns>
<ej:Column Field="OrderID" HeaderText="Order ID" IsPrimaryKey="true" TextAlign="Right"Width="90" />
<ej:Column Field="CustomerID" HeaderText="Customer ID" Width="100" />
<ej:Column Field="EmployeeID" HeaderText="Employee ID" HeaderTemplateID="#employeeTemplate"TextAlign="Right" Width="110" />
<ej:Column Field="Freight" HeaderText="Freight" TextAlign="Right" Width="90" Format="{0:C}"/>
<ej:Column Field="OrderDate" HeaderText="Order Date" Width="100"HeaderTemplateID="#dateTemplate" TextAlign="Right" Format="{0:MM/dd/yyyy}" />
<ej:Column Field="ShipCity" HeaderText="Ship City" Width="100" />
</Columns>
</ej:Grid>
[Code behind]
Protected Sub Grid1_ServerRowSelected(sender As Object, e As Syncfusion.JavaScript.Web.GridEventArgs)
Dim data As Dictionary(Of String, Object) = DirectCast(e.Arguments("data"), Dictionary(Of String,Object))
Dim CustomerID As String = ""
For Each items As KeyValuePair(Of String, Object) In data
If items.Key = "CustomerID" Then
CustomerID = items.Value.ToString()
End If
Next
End Sub |