I have a requirement and need to evaluate if RadGridView can support this.
I need to display hierarchical data in the grid. The data can span unto 4 levels. To clarify it further, say I have Manufacturer, Retailer and consumer. Here the consumer can directly purchase from a manufacturer. Or he can consume from a retailer. Also retailer can purchase from the manufacturer. I am interested in showing up the data in a user friendly format. I have tried these 2 options
1. Group by feature and realized that even when the consumer purchases directly from Manufacturer, the data for the consumer is displayed at 3rd level. Since the data is grouped on Manufacturer and then the Retailer. So here the consumer is shown as Manufacturer1-> Retailer (EMPTY)-> Consumer.
2. The other option was showing the data establishing relationship between tables. This served the purpose but the view is unfriendly. The user has to scroll up and down too much to view the data.
Please let me know if there is a possibility with RadGridView to support this requirement. To summarize it, I need to display data hierarch ally where I have Manufacturer, Retailer and Consumer. The Consumer can purchase from both Retailer and Manufacturer. And Retailer can buy only from Manufacturer. So the hierarchy can be
| System.Collections.IDictionaryEnumerator iterator = sortedRuleKeys.GetEnumerator(); while (iterator.MoveNext()) { GridViewRowInfo rowInfo = radGridView_RuleKeys.Rows.AddNew(); rowInfo.Cells[0].Value = ((RuleKey)iterator.Value).RuleKeyGuid.ToString(); rowInfo.Cells[1].Value = ((RuleKey)iterator.Value).keyName; rowInfo.Cells[2].Value = ((RuleKey)iterator.Value).keyValue; } ((GridViewLookUpColumn)radGridView_RuleKeys.Columns[1]).AutoCompleteMode = AutoCompleteMode.SuggestAppend; |
| ((GridViewLookUpColumn)radGridView_RuleKeys.Columns[1]).DropDownStyle = RadDropDownStyle.DropDown; |
| DataTable dt = new DataTable(); |
| dt.Columns.Add("RuleKey", typeof(string)); |
| dt.Rows.Add("Mobile"); |
| dt.Rows.Add("Business"); |
| dt.Rows.Add("Fax"); |
| ((GridViewLookUpColumn)radGridView_RuleKeys.Columns[1]).DataSource = dt; |
| private void ManageLocations_Load(object sender, EventArgs e) |
| { |
| this.wISE_LocationsTableAdapter.Fill(this.locations.WISE_Locations); |
| } |
| private void InsertLoc() |
| { |
| sh.InsertLoc(txtName.Text, txtZip.Text, string.Empty, string.Empty); |
| this.rgLocations.Rows.Add(txtName.Text, txtZip.Text); |
| this.UpdatePanelInfo(this.rgLocations.CurrentRow); |
| } |