GridViewRelation selfRelaction = new GridViewRelation(this.radGridView1.MasterTemplate, this.radGridView1.MasterTemplate); selfRelaction.ParentColumnNames.Add("column1"); selfRelaction.ChildColumnNames.Add("column2"); this.radGridView1.Relations.Add(selfRelaction); this.radGridView1.Columns["column1"].IsVisible = false; this.radGridView1.Columns["column2"].IsVisible = false; this.radGridView1.Rows.Add(1, null, "1", "1", "1", "1"); this.radGridView1.Rows.Add(2, 1, "1", "1", "1", "1"); this.radGridView1.Rows.Add(3, null, "1", "1", "1", "1"); this.radGridView1.Rows.Add(4, 3, "1", "1", "1", "1"); this.radGridView1.Rows.Add(5, null, "1", "1", "1", "1");
//error : radGridView1.Rows.Count is "0"!this.radGridView1.Rows[0].IsExpanded = true; this.radGridView1.Rows[2].IsExpanded = true;
radGridView1.Rows.Count is "0"!
Help me! Both Q2 and Q3!