Back to Devexpress

Series.BindToData(Object, String, String[]) Method

corelibraries-devexpress-dot-xtracharts-dot-series-dot-bindtodata-x28-system-dot-object-system-dot-string-system-dot-string-x29.md

latest3.6 KB
Original Source

Series.BindToData(Object, String, String[]) Method

Binds a series to data.

Namespace : DevExpress.XtraCharts

Assembly : DevExpress.XtraCharts.v25.2.dll

NuGet Package : DevExpress.Charts

Declaration

csharp
public void BindToData(
    object dataSource,
    string argumentDataMember,
    params string[] valueDataMembers
)
vb
Public Sub BindToData(
    dataSource As Object,
    argumentDataMember As String,
    ParamArray valueDataMembers As String()
)

Parameters

NameTypeDescription
dataSourceObject

A Object that is the datasource for a series. This value is assigned to the Series.DataSource property.

| | argumentDataMember | String |

A String that is the name of the data field that contains arguments for series points. This value is assigned to the SeriesBase.ArgumentDataMember property of a series.

| | valueDataMembers | String[] |

An array of String values that are the names of data fields that contain information on data values of series points. These values are assigned to the SeriesBase.ValueDataMembers property of a series.

|

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the BindToData(Object, String, String[]) method.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

winforms-charts-change-series-line-color-when-value-is-under-predefined-level/CS/Form1.cs#L28

csharp
Series series = new Series();
series.BindToData(PointGenerator.Generate(), "X", "Y");
series.ColorDataMember = "Y";

winforms-charts-change-series-line-color-when-value-is-under-predefined-level/VB/Form1.vb#L32

vb
Dim series As Series = New Series()
series.BindToData(PointGenerator.Generate(), "X", "Y")
series.ColorDataMember = "Y"

See Also

Series Class

Series Members

DevExpress.XtraCharts Namespace