or

I want to run separate query in each grid view, these grids is located in deferent taps that was created via dockā¦
Is that possible in rad grid view for win form?
The information I need to add is retrieved from the same DB
string[] strArr = { "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "A", "B", "C", "D", "E", "F", "21", "22", "23", "24", "25", "26", "27", "2", "3", "4", "5", "6", "7", "8", "9", "10", "A", "B", "C", "D", "2", "3", "4", "5", "6", "7", "8", "9", "10", "A", "B", "C", "D", "2", "3", "4", "5", "6", "7", "8", "9", "10", "A", "B", "C", "D", "2", "3", "4", "5", "6", "7", "8", "9", "10" };private void CreateColumnRow() { DataTable data = new DataTable(); data.Columns.Add("1"); data.Columns.Add("2"); data.Columns.Add("3"); data.Columns.Add("4"); data.Columns.Add("5"); for (int i = 0; i < strArr.Length / 5; i++) { DataRow dr = data.NewRow(); data.Rows.InsertAt(dr, 0); } int intSub = strArr.Length % 5; if (intSub > 0) { DataRow dr = data.NewRow(); data.Rows.InsertAt(dr, 1); } radGridView1.DataSource = data; radGridView1.Columns[0].Width = 100; radGridView1.Columns[1].Width = 100; radGridView1.Columns[2].Width = 100; radGridView1.Columns[3].Width = 100; radGridView1.Columns[4].Width = 100; } private void Form1_Load(object sender, EventArgs e) { CreateColumnRow(); loadCheckBox(); } private void loadCheckBox(){ int z = 0; for (int i = 0; i < radGridView1.RowCount; i++) { for (int j = 0; j < radGridView1.ColumnCount; j++) { radGridView1.Rows[i].IsCurrent = true; radGridView1.Columns[j].IsCurrent = true; if (radGridView1.CurrentColumn.Index == j && radGridView1.CurrentRow.Index == i) { RadCheckBoxElement check = null; if (radGridView1.CurrentCell.Children.Count == 0) { check = new RadCheckBoxElement(); while (z < strArr.Length) { check.Name = "check_" + strArr[z]; check.Text = strArr[z]; radGridView1.CurrentCell.Children.Add(check); z++; break; } } else { check = (RadCheckBoxElement)radGridView1.CurrentCell.Children[0]; } } if (z == strArr.Length) { break; } } if (z == strArr.Length) { break; } } radGridView1.Rows[0].IsCurrent = true; radGridView1.Columns[0].IsCurrent = true;}
| this.tvCustomers.RootRelationDisplayName = "Customers"; |
| this.tvCustomers.DisplayMember = "tbContact.Name"; |
| thisthis.tvCustomers.DataSource = this.bsCustomers; |
| void Nodes_CollectionChanged(object sender, Telerik.WinControls.Data.NotifyCollectionChangedEventArgs e) |
| { |
| if(e.Action==Telerik.WinControls.Data.NotifyCollectionChangedAction.Add) |
| { |
| if (((RadTreeNode)e.NewItems[0]).Level == 0) |
| return; |
| ((RadTreeNode)e.NewItems[0]).Text = ((Customer)this.bsCustomers[e.NewStartingIndex]).tbContact.Name; |
| } |
| } |


