Method AddSeries
- Namespace
- DocWright.Spreadsheet
- Assembly
- DocWright.Spreadsheet.dll
AddSeries(string, string?, string?)
Adds a series to the chart's (first) plot, after its last.
public void AddSeries(string values, string? categories = null, string? name = null)
Parameters
valuesstringThe range of its values (a scatter's y values), such as
Data!$E$2:$E$6.categoriesstringThe range of its categories (a scatter's x values); null for none.
namestringThe cell its name is read from; null for none.
Exceptions
- ArgumentNullException
valuesis null.- ArgumentException
A reference is not a range of a sheet of the workbook.
- InvalidOperationException
The chart has 255 series, its plot is not one made here, it is a 2016 chart, or it was removed.