mobilecontrols-devexpress-dot-xamarinforms-dot-charts-4051e402.md
Specifies a data source field that contains data for series point values.
Namespace : DevExpress.XamarinForms.Charts
Assembly : DevExpress.XamarinForms.Charts.dll
NuGet Package : DevExpress.XamarinForms.Charts
public class ValueDataMember :
BindableObject
ChartView supports two ways to populate series with data from an external data source.
Create series and bind them to data sources
Do the following to add series of different types to the chart and specify an individual data source for each series:
See the following help topic for an example: Bind Chart Series to Data.
Generate series from a data source based on a template
You can set up the ChartView so that it uses the specified template to generate series from the bound data source. To do this, set the ChartView.SeriesDataTemplate property to a SeriesTemplateAdapter object and specify this adapter’s properties:
See the following help topic for an example: Generate Series from a Data Source.
In both cases, ValueDataMembers is a collection of data source fields that contain data values for series points. The number of items in this collection ( ValueDataMember objects) depends on the series type. Most series types (except for financial, range bar, range area, and bubble) require one value to build each point of the series.
Use the ValueDataMember.Type and ValueDataMember.Member properties to specify the value type and data source field that contains data for series point values.
These examples show how to create and configure the data adapter to populate ChartView series of different types with data.
For most series types supported by ChartView (besides financial, range bar and bubble charts), specify one ValueDataMember object with the Type set to Value :
For financial series (CandleStickSeries and StockSeries), specify four ValueDataMember objects with Type set to High , Low , Open , and Close :
For RangeBarSeries, specify two ValueDataMember objects with Type set to High and Low :
For BubbleSeries, specify two ValueDataMember objects with Type set to Value and Weight :
Object ValueDataMember
See Also