Reference > Methods > SetSeriesNames Method

SharpPlot.SetSeriesNames Method

Assign a non-default name or names to the upcoming data series.

Example

sp.SetSeriesNames(new string[]{"Budget","Forecast"});

Overloads

Description

This call will add the series name to the id tag in any web-formatted output. This makes it easy to write JavaScript which changes the elements as you mouse-over them or click on them (for example emphasising the border on mouse-enter).

It is also very helpful if your application is tracking hotspots using the Active Charts components, as you can output meaningful hotspot information to the console. For example:

Chart=Bar1, Series=Hats, Item=2, Type=Bar, Locator=186.9 52 216 193.2 0

Here the chart was named “Bar1” and the two series were named “Hats,Coats”. You could use the feedback from this structure to implement drill-down to get the detail of the ‘Hats’ series, second item.

See also ...

SharpPlot Members | SetChartName Method | HotspotInfo Struct | PageMap Class – Introduction


Send comments on this topic
© Dyalog Ltd 2013