Add a Chart Series

Introduction

In Microsoft PowerPoint, chart series refer to the data sets or collections of data points that are represented on a chart. When you create a chart in PowerPoint, you typically have multiple sets of data that you want to visualize, and each of these sets is known as a chart series. Chart series are essential for conveying information effectively and comparing different data categories. Use the following method to add a chart series to a presentation chart.

CreateChartSeries

API Information

API Type Description Resource
/slides/{name}/slides/{slideIndex}/shapes/{shapeIndex}/series POST Adds a data series to a chart in a presentation saved in a storage. CreateChartSeries

Request Parameters

Name Type Location Required Description
name string path true The name of a presentation file saved in a storage.
slideIndex integer path true The 1-based index of a presentation slide.
shapeIndex integer path true The 1-based index of a shape (must be a chart).
series Series body true The data transfer object with a series of data.
password string header false The password to open the presentation.
folder string query false The path to a folder containing the presentation.
storage string query false The name of the storage contaning the folder.

Examples

The document MyPresentation.pptx, saved in the default storage, contains a chart (the second shape) with two lines on the first slide - sales volumes of products “Product A” and “Product B” for 2021 to 2023. Add series data (30, 20, 25) on the sales of Product C for the same years.

Sales chart

cURL Solution

SDK Solutions

The result:

Sales chart

SDKs

Check Available SDKs to learn how to add an SDK to your project.