how to access the parent table column value in child table when we using the hierarchy of telerik grid.
cs source-
protected void cmpreportgrid_OnItemDataBound(object sender, Telerik.Web.UI.GridItemEventArgs e)
{
if (e.Item is GridDataItem)
{
if (e.Item.OwnerTableView.Name == "CompanyListDetails")
{
if (e.Item is GridDataItem)
{
GridDataItem item = e.Item as GridDataItem;
Viewing view = item.DataItem as Viewing;
if (!view.isgroupcontact)
{
item["ExpandColumn"].Text = "";
}
}
}
else if (e.Item.OwnerTableView.Name == "GroupContact")
{
e.Item.OwnerTableView.ParentItem.Expanded=false;//how to get the parent table column here to set the condition for expandcolumn.
}
}
}
cs source-
protected void cmpreportgrid_OnItemDataBound(object sender, Telerik.Web.UI.GridItemEventArgs e)
{
if (e.Item is GridDataItem)
{
if (e.Item.OwnerTableView.Name == "CompanyListDetails")
{
if (e.Item is GridDataItem)
{
GridDataItem item = e.Item as GridDataItem;
Viewing view = item.DataItem as Viewing;
if (!view.isgroupcontact)
{
item["ExpandColumn"].Text = "";
}
}
}
else if (e.Item.OwnerTableView.Name == "GroupContact")
{
e.Item.OwnerTableView.ParentItem.Expanded=false;//how to get the parent table column here to set the condition for expandcolumn.
}
}
}