dxTreeMap
Namespace: Wisej.Web.Ext.DevExtreme
Assembly: Wisej.Web.Ext.DevExtreme (4.1.0.0)
The TreeMap is a widget that displays hierarchical data by using nested rectangles.
- C#
- VB.NET
public class dxTreeMap : dxBase
Public Class dxTreeMap
Inherits dxBase
Constructors
dxTreeMap()
Constructs a new instance of the dxTreeMap class.
Example:
The following example creates a tree map that sizes each rectangle by the population of a city.
var treeMap = new dxTreeMap();
treeMap.Options.dataSource = new[]
{
new { name = "Tokyo", value = 13929 },
new { name = "Delhi", value = 11034 },
new { name = "Shanghai", value = 24183 }
};
treeMap.Options.title = "Population (thousands)";
treeMap.Options.tooltip = new { enabled = true };
treeMap.Dock = DockStyle.Fill;
this.Controls.Add(treeMap);
dxTreeMap(options)
Constructs a new instance of the dxTreeMap class.
| Name | Type | Description |
|---|---|---|
| options | Object | Initial set of options. |
Example:
The following example creates a tree map from hierarchical data that uses custom field names.
var treeMap = new dxTreeMap(new
{
dataSource = new[]
{
new
{
category = "Europe",
children = new[]
{
new { category = "Germany", sales = 510 },
new { category = "Italy", sales = 340 }
}
}
},
labelField = "category",
valueField = "sales",
childrenField = "children",
layoutAlgorithm = "squarified"
});
treeMap.Dock = DockStyle.Fill;
this.Controls.Add(treeMap);