I have a RadGrid that has a Master Table and a child and grandchild
Master
Child
Grandchild
I am using the OnItemCommand and I can't seem to access the Datakey's that are listed in the Grandchild.
Your help is appreciated.
Master
Child
Grandchild
I am using the OnItemCommand and I can't seem to access the Datakey's that are listed in the Grandchild.
foreach (GridDataItem item in rg1.MasterTableView.Items)
{
long Id1 = (long)rg1.MasterTableView.Items[0].GetDataKeyValue("Id1");
if (item.HasChildItems)
{
foreach (GridDataItem citem in item.ChildItem.NestedTableViews[0].Items)
{
string Id = citem.GetDataKeyValue("Id2").ToString();
}
}
}
<
MasterTableView
DataKeyNames
=
"Id1"
Name
=
"Master"
>
<
DetailTables
>
<
telerik:GridTableView
DataKeyNames
=
"Id1,Id2"
Name
=
"Child"
>
<
DetailTables
>
<
telerik:GridTableView
DataKeyNames
=
"Id1,Id2,Id3"
Name
=
"Grandchild"
EditMode
=
"InPlace"
>
<
Columns
>
Your help is appreciated.