using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

public partial class pages_Grid_Hierarchy_DetailTableAggregates : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!Page.IsPostBack)
        {
            //Setting Selected index prior to binding RadGrid:
            //If the index is in detail table, parent items will be expanded
            //automatically 
            RadGrid1.SelectedIndexes.Add(1, 0, 1, 0, 1);
            //Index of 1, 0, 1, 0, 1 means:
            //1 - item with index 1 in the MasterTabelView
            //0 - detail table with index 0
            //1 - item with index 1 (the second item) in the first detail table
            //0 - 0 the third-level detail table
            //1 - select item with index 1 in the third-level table
        }
    }
}
