Table of Contents

TTMSFNCStackedPercentageAreaChart.LoadFromJSONData Method

Imports series and points from a JSON file; specify JSON key names for series, points, and y-values.

API unit family: TMSFNCChart Declaring type: TTMSFNCStackedPercentageAreaChart Inherited from: TTMSFNCChart

Overloads

Overload 1

Imports series and points from a JSON file; specify JSON key names for series, points, and y-values.

procedure LoadFromJSONData(AFileName: string; ASeriesName: string; APointsName: string; AYValueName: string; AXValueName: string = ''; AXLabelName: string = ''; ASerieCallBack: TTMSFNCChartAddJSONSerieCallBackEvent = nil; APointCallBack: TTMSFNCChartAddJSONPointCallBackEvent = nil ); overload; virtual;

Parameters

Name Description
AFileName Path of the JSON file to import.
ASeriesName JSON array key containing the series objects.
APointsName JSON array key within each series object containing the point objects.
AYValueName JSON key for the primary y-value of each point.
AXValueName JSON key for the x-value; leave empty to use sequential indexes.
AXLabelName JSON key for the x-axis label text; leave empty to omit.
ASerieCallBack Optional callback to customize each series after it is created.
APointCallBack Optional callback to customize each point after it is created.

Overload 2

Imports series and points from a JSON file using explicit load options.

procedure LoadFromJSONData(AFileName: string; ALoadOptions: TTMSFNCChartLoadOptions; ASeriesName: string; APointsName: string; AYValueName: string; AXValueName: string = ''; AXLabelName: string = ''; ASerieCallBack: TTMSFNCChartAddJSONSerieCallBackEvent = nil; APointCallBack: TTMSFNCChartAddJSONPointCallBackEvent = nil ); overload; virtual;

Parameters

Name Description
AFileName Path of the JSON file.
ALoadOptions Import options controlling range and format.
ASeriesName JSON array key for series objects.
APointsName JSON array key for point objects.
AYValueName JSON key for the primary y-value.
AXValueName JSON key for x-values; empty for sequential.
AXLabelName JSON key for x-axis labels; empty to omit.
ASerieCallBack Optional series callback.
APointCallBack Optional point callback.

Overload 3

Imports multiple series from a JSON file using arrays of JSON key names for y, x, and label values.

procedure LoadFromJSONData(AFileName: string; ASeriesName: string; APointsName: string; AYValueNames: TTMSFNCChartJSONNamesArray = nil; AXValueNames: TTMSFNCChartJSONNamesArray = nil; AXLabelNames: TTMSFNCChartJSONNamesArray = nil; ASerieCallBack: TTMSFNCChartAddJSONSerieCallBackEvent = nil; APointCallBack: TTMSFNCChartAddJSONPointCallBackEvent = nil ); overload; virtual;

Parameters

Name Description
AFileName Path of the JSON file.
ASeriesName JSON array key for series objects.
APointsName JSON array key for point objects.
AYValueNames Array of JSON key names for y-values per series; nil uses the first y-value key.
AXValueNames Array of JSON key names for x-values; nil for sequential.
AXLabelNames Array of JSON key names for x-axis labels; nil to omit.
ASerieCallBack Optional series callback.
APointCallBack Optional point callback.

Overload 4

Imports multiple series from a JSON file using key name arrays and explicit load options.

procedure LoadFromJSONData(AFileName: string; ALoadOptions: TTMSFNCChartLoadOptions; ASeriesName: string; APointsName: string; AYValueNames: TTMSFNCChartJSONNamesArray = nil; AXValueNames: TTMSFNCChartJSONNamesArray = nil; AXLabelNames: TTMSFNCChartJSONNamesArray = nil; ASerieCallBack: TTMSFNCChartAddJSONSerieCallBackEvent = nil; APointCallBack: TTMSFNCChartAddJSONPointCallBackEvent = nil ); overload; virtual;

Parameters

Name Description
AFileName Path of the JSON file.
ALoadOptions Import options.
ASeriesName JSON array key for series objects.
APointsName JSON array key for point objects.
AYValueNames Array of JSON key names for primary y-values.
AXValueNames Array of JSON key names for x-values; nil for sequential.
AXLabelNames Array of JSON key names for x-axis labels; nil to omit.
ASerieCallBack Optional series callback.
APointCallBack Optional point callback.