New to Telerik UI for ASP.NET Core? Start a free 30-day trial

Defines the fluent API for configuring List<ChartXAxisPlotBand<T>>

Definition

Namespace:Kendo.Mvc.UI.Fluent

Assembly:Kendo.Mvc.dll

Type Parameters:

T

Syntax:

C#
public class ChartXAxisPlotBandFactory<T> where T : class

Inheritance: objectChartXAxisPlotBandFactory<T>

Inherited Members object.GetType()object.MemberwiseClone()object.ToString()object.Equals(object)object.Equals(object, object)object.ReferenceEquals(object, object)object.GetHashCode()...

Constructors

Initializes a new instance of the ChartXAxisPlotBandFactory<T> class.

C#
public ChartXAxisPlotBandFactory(List<ChartXAxisPlotBand<T>> container)
Parameters:containerList<ChartXAxisPlotBand<T>>

The List<ChartXAxisPlotBand<T>> container

Properties

Chart member.

C#
public Chart<T> Chart { get; set; }

Gets the List<ChartXAxisPlotBand<T>> container.

C#
protected List<ChartXAxisPlotBand<T>> Container { get; }

Methods

Adds an item to the collection

C#
public virtual ChartXAxisPlotBandBuilder<T> Add()
Returns:

ChartXAxisPlotBandBuilder<T>

Returns a ChartXAxisPlotBandBuilder<T> with the available configuration options.

Adds an item to the plot bands collection.

C#
public virtual ChartXAxisPlotBandBuilder<T> Add(double from, double to, string color)
Parameters:fromdouble

The start position of the plot band in axis units.

todouble

The end position of the plot band in axis units.

colorstring

The color of the plot band.

Returns:

ChartXAxisPlotBandBuilder<T>

Returns a new instance of ChartXAxisPlotBandBuilder<T> for further configuration.

Example:
C#
@(Html.Kendo().Chart()
.Name("chart")
.XAxis(axis =&gt;
{
axis.PlotBands(bands =&gt;
{
bands.Add(20000, 40000, "green");
});
})
)