-
Notifications
You must be signed in to change notification settings - Fork 599
word chart series
goworm edited this page Jun 26, 2026
·
1 revision
Per-series data and styling within an embedded chart — values, categories, fill color, line/marker formatting, and series name.
Path: /chart[N]/series[K]
-
add - Series are added as dotted props on the parent chart at Add time (
series1.name,series1.values, ...) - set - Modify a series after creation
- get - Read series attributes
- remove - Delete a series
At Add time, series are passed as dotted props on the parent chart element, not on chart-series directly. Prefix each property with the series index (series1., series2., ...).
| Property | Required/Default | Description |
|---|---|---|
name (alias title) |
Series name shown in legend and data labels | |
values |
Comma-separated numbers OR a cell range reference (Sheet1!B2:B13) |
|
categories |
Per-series category override; range reference only | |
color |
Series fill color | |
bubbleSize |
Bubble chart per-point sizes; comma-separated numbers OR a cell range reference. Defaults to the y-values when omitted. (bubble charts only) | |
bubbleSizeRef |
A1 cell range backing bubble per-point sizes. Coexists with bubbleSize (the literal becomes the numCache). (bubble charts only) |
Modifies a single series identified by its path (/chart[N]/series[K]).
| Property | Required/Default | Description |
|---|---|---|
name (alias title) |
Series name shown in legend and data labels | |
values |
Comma-separated numbers OR a cell range reference (Sheet1!B2:B13) |
|
categories |
Per-series category override; range reference only | |
color |
Series fill color | |
lineWidth |
Series line width in points (e.g. 1.5) |
|
lineDash (alias dash) |
Series line dash style. Set accepts user-friendly aliases (dash/dot/dashDot/longDash); Get returns the OOXML token. solid is the only round-trip-stable value. |
|
marker |
Per-series marker symbol: circle, dash, diamond, dot, plus, square, star, triangle, x, none, auto. Supports the symbol:size:COLOR compound form (e.g. circle:8:FF0000). Applies to line/scatter/radar series. |
|
markerSize |
Marker size in points (2–72). Applies when marker is not none. |
|
markerColor (alias marker.color) |
Per-series marker fill color (line/scatter/radar). Preserves existing symbol and size — pair with marker=/markerSize= to set the triplet independently. |
|
smooth |
Smooth line interpolation for line/scatter series (true|false) |
|
errBars |
Error bar value type: fixed, percent, stddev, stderr (aliases fixedValue, percentage/pct, standardDeviation, standardError). Pass none to clear. Silently ignored on series types that don't support error bars. |
|
invertIfNeg |
Invert color for negative values. Bar/column/area/pie series only; line/scatter silently ignore. |
solid, sysDash, sysDot, sysDashDot, lgDash, lgDashDot, lgDashDotDot, dash, dashDot, dot, longDash
| Attribute | Type | Description |
|---|---|---|
name |
string | Series name string |
nameRef |
string | A1 cell reference backing the series name |
values |
string | Series values |
categories |
string | Per-series category override |
categoriesRef |
string | A1 cell range backing the category labels |
color |
color | Series fill color (#-prefixed uppercase hex) |
lineWidth |
number | Line width in points |
lineDash |
string | OOXML preset dash token |
marker |
string | Marker symbol name |
markerSize |
number | Marker size (integer) |
markerColor |
string | Marker fill color (hex, e.g. #FF0000) |
smooth |
string |
true | false
|
errBars |
string | OOXML errValType token |
invertIfNeg |
string |
true | false
|
scatterStyle |
string | Scatter sub-style (line/lineMarker/marker/smooth/smoothMarker/none) |
secondaryAxis |
bool |
true when the chart has more than one value axis (this series uses the secondary) |
dataLabels.numFmt |
string | Per-series data label number format code |
dataLabels.separator |
string | Per-series data label separator string |
bubbleSize |
string | Bubble per-point sizes (comma-separated cached values) |
bubbleSizeRef |
string | A1 cell range backing bubble per-point sizes |
# Add a chart with two series (series props are dotted on the parent chart)
officecli add report.docx /chart[1] \
--prop series1.name="Q1" \
--prop series1.values="120,150,180,210" \
--prop series1.color=#4472C4 \
--prop series1.categories="Sheet1!$A$2:$A$5"
# Set a series name and fill color after creation
officecli set report.docx /chart[1]/series[1] \
--prop name="Revenue" \
--prop color=4472C4
# Style a line series: width, dash, smoothing
officecli set report.docx /chart[1]/series[1] \
--prop lineWidth=1.5 \
--prop lineDash=dash \
--prop smooth=true
# Set the marker triplet (symbol, size, color)
officecli set report.docx /chart[1]/series[1] \
--prop marker="circle:8:FF0000"
# Or set marker parts independently
officecli set report.docx /chart[1]/series[1] \
--prop marker=circle \
--prop markerSize=8 \
--prop markerColor=FF0000
# Add a bubble series with per-point sizes
officecli add report.docx /chart[1] \
--prop series1.values="120,150,180" \
--prop series1.bubbleSize="10,20,30"
# Read a series
officecli get report.docx /chart[1]/series[1]
# Remove a series
officecli remove report.docx /chart[1]/series[1]- At Add time, series pass as dotted props on the parent chart (
series1.name,series1.values,series1.color,series1.categories). This element's schema covers per-series Set/Get after creation. - Combo charts (mixed chart type / secondary axis) are unsupported — create separate charts instead.
-
lineStyleis not a valid key (rejected as unsupported) — uselineWidth+lineDash. -
lineDash:solidis the only round-trip-stable value;dashDotDotis accepted as an alias forsysDashDotDot, and Get readback returns the OOXML token. -
marker: picture markers are not implemented. -
smoothapplies to line/scatter series;errBarsandinvertIfNegare silently ignored on series types that don't support them.
- Chart - Parent embedded chart element
- Add Chart - Creating charts and their series
- Word Reference - All Word elements
Based on OfficeCLI v1.0.119