windowsforms-devexpress-dot-xtratreemap-5408f5ec.md
Displays an interactive Sunburst chart.
Namespace : DevExpress.XtraTreeMap
Assembly : DevExpress.XtraTreeMap.v25.2.UI.dll
NuGet Package : DevExpress.Win.TreeMap
[ComVisible(true)]
[DXLicenseWinForms]
public class SunburstControl :
HierarchicalChartControlBase
<ComVisible(True)>
<DXLicenseWinForms>
Public Class SunburstControl
Inherits HierarchicalChartControlBase
The following image shows a sunburst chart:
The Sunburst control ships with a set of data adapters that allow you to generate items based on Flat Data Tables and Hierarchical Data Sets. You can also populate sunburst item storage manually. Sunburst allows you to specify how to group items on each level of the hierarchy.
You can use the built-in coloring algorithms to specify the sunburst items colors. Add a legend to the sunburst to show descriptions of colors used to paint sunburst items. You can also add multiple titles to include other explanatory information to the sunburst.
The Sunburst control supports multiple item selection. You can operate with selected items and use them as another control’s data source.
Sunburst allows you to use various highlight modes. End users can highlight the following elements at once:
To get acquainted with the SunburstControl , please refer to the following section: Getting Started.
This example demonstrates how to visualize flat data using the SunburstControl.
Create a SunburstFlatDataAdapter object and assign it to the SunburstControl.DataAdapter property to provide flat data to the Sunburst. Then, specify the adapter’s SunburstFlatDataAdapter.DataSource, SunburstFlatDataAdapter.LabelDataMember and SunburstFlatDataAdapter.ValueDataMember to define data source members that should be used to generate sunburst items. Add data members to the SunburstFlatDataAdapter.GroupDataMembers collection to specify how to group the sunburst’s items.
private void OnLoad(object sender, EventArgs e) {
SunburstFlatDataAdapter dataAdapter = new SunburstFlatDataAdapter();
dataAdapter.ValueDataMember = "Annual";
dataAdapter.LabelDataMember = "Product";
dataAdapter.GroupDataMembers.AddRange(new string[] { "Category", "Country" });
dataAdapter.DataSource = CreateProductInfos();
sunburstControl.DataAdapter = dataAdapter;
}
Class SurroundingClass
Private Sub OnLoad(ByVal sender As Object, ByVal e As EventArgs)
Dim dataAdapter As SunburstFlatDataAdapter = New SunburstFlatDataAdapter()
dataAdapter.ValueDataMember = "Annual"
dataAdapter.LabelDataMember = "Product"
dataAdapter.GroupDataMembers.AddRange(New String() {"Category", "Country"})
dataAdapter.DataSource = CreateProductInfos()
sunburstControl.DataAdapter = dataAdapter
End Sub
End Class
Object MarshalByRefObject Component Control DevExpress.XtraEditors.XtraControl HierarchicalChartControlBase SunburstControl
See Also