dxSparkline
Namespace: Wisej.Web.Ext.DevExtreme
Assembly: Wisej.Web.Ext.DevExtreme (4.1.0.0)
The Sparkline widget is a compact chart that contains only one series.
- C#
- VB.NET
public class dxSparkline : dxBase
Public Class dxSparkline
Inherits dxBase
Constructors
dxSparkline()
Constructs a new instance of the dxSparkline class.
Example:
The following example creates a sparkline from a list of numbers and highlights the minimum and maximum values.
var sparkline = new dxSparkline();
sparkline.Options.dataSource = new[] { 4, 8, 6, 9, 5, 11, 7 };
sparkline.Options.type = "line";
sparkline.Options.showMinMax = true;
sparkline.Size = new Size(160, 40);
this.Controls.Add(sparkline);
dxSparkline(options)
Constructs a new instance of the dxSparkline class.
| Name | Type | Description |
|---|---|---|
| options | Object | Initial set of options. |
Example:
The following example creates a bar sparkline bound to a list of objects.
var sparkline = new dxSparkline(new
{
dataSource = new[]
{
new { month = 1, profit = 120 },
new { month = 2, profit = -40 },
new { month = 3, profit = 85 }
},
argumentField = "month",
valueField = "profit",
type = "bar"
});
sparkline.Size = new Size(160, 40);
this.Controls.Add(sparkline);