LegendText

Gets or Sets the text that must appear in the legends for the series.

 

Type: String

Namespace: Visifire.Charts

Assembly:

 

Silverlight:

SLVisifire.Charts (in SLVisifire.Charts.dll)

WPF:

WPFVisifire.Charts (in WPFVisifire.Charts.dll)

Windows Phone:

SLWpVisifire.Charts (in SLWpVisifire.Charts.dll)

Windows 8:

Win8Visifire.Charts (in Win8Visifire.Charts.dll)

 

This attribute applies to:

 

 

Syntax:

<vc:Chart ... >

<vc:Chart.Series>

<vc:DataSeries>

      <vc:DataPoint LegendText="DataPoint1"/>

      <vc:DataPoint LegendText="DataPoint2"/>

</vc:DataSeries>

</vc:Chart.Series>

</vc:Chart>

 

Below is the chart after applying LegendText property:

 

legendtext.jpg

 

Modifiers:

 

Modifier

Description

#AxisXLabel

Returns the axis label value if axis labels is present for that XValue. Otherwise returns XValue.

#Percentage

Returns the percentage value with respect to DataPoints in that series.

#Series

Returns the series name.

#Sum

Returns sum of values in entire chart with same XValue. (Used for stacked charts only)

#XValue

Returns XValue.

#YValue

Returns YValue.

#ZValue

Returns ZValue.

#Open

Returns Open value.

#Close

Returns Close value.

#High

Returns High value.

#Low

Returns Low value.

 

Remarks:

  1. The above modifiers are applicable for LegendText set in DataPoint or DataSeries only.

  2. Modifiers can be used in any combination to display DataPoint specific content.

  3. To display the modifier itself use the '#' twice. For example to display "#XValue" as label use LegendText="##XValue"

  4. The default value for LegendText in Pie/Doughnut and Funnel charts is "AxisXLabel, #YValue".

  5. The default value for LegendText in CandleStick and Stock charts is "#Close".

  6. The default value for LegendText in all other charts is "#YValue".

  7. For CandleStick and Stock charts, LegendText can be set as LegendText="#Open, #Close, #High, #Low, #YValue". For CandleStick and Stock charts, volume information can be stored in YValue property and can be showed as a LegendText for DataPoints. Note that YValue property is not being used in CandleStick and Stock charts.

  8. For Stacked charts, percentage will be calculated from the DataPoints present in each XValue. In other words, percentage will be calculated for stacked DataPoints (in each XValue) from all series.

  9. For CandleStick and Stock charts, percentage will be calculated for Closing price in DataPoints.