chart_series_set_name

@brief Set the name of a chart series range.

@param series A series object created via chart_add_series(). @param name The series name.

The %chart_series_set_name function is used to set the name for a chart data series. The series name in Excel is displayed in the chart legend and in the formula bar. The name property is optional and if it isn't supplied it will default to Series 1..n.

The function applies to a #lxw_chart_series object created using chart_add_series():

@code lxw_chart_series *series = chart_add_series(chart, NULL, "=Sheet1!$B$2:$B$7");

chart_series_set_name(series, "Quarterly budget data"); @endcode

The name parameter can also be a formula such as =Sheet1!$A$1 to point to a cell in the workbook that contains the name:

@code lxw_chart_series *series = chart_add_series(chart, NULL, "=Sheet1!$B$2:$B$7");

chart_series_set_name(series, "=Sheet1!$B1$1"); @endcode

See also the chart_series_set_name_range() function to see how to set the name formula programmatically.

extern (C)
void
chart_series_set_name

Meta