Working with a Slide Background

Introduction

Aspose.Slides Cloud API makes it easy to read, update, and delete the background of any slide in a PowerPoint presentation. The presentation must already be saved to a Cloud storage. You can set different background types, such as solid color, gradient, pattern, and image. Many effects can also be applied to the slide background (blur, glow, shadows, reflections, etc.).

GetBackground

API Information

API Type Description Resource
/slides/{name}/slides/{slideIndex}/background GET Reads information about the background applied to a presentation slide. GetBackground

Request Parameters

Name Type Location Required Description
name string path true The name of a presentation file.
slideIndex integer path true The 1-based index of the slide to read the background.
password string header false The password to open the presentation.
folder string query false The path to the folder containing the presentation.
storage string query false The name of the storage contaning the folder.

In case of Amazon S3 storage folder path starts with Amazon S3 bucket name.

Examples

Get the background type of the first slide from MyFolder/MyPresentation.pptx file saved to the default storage.

cURL Solution

SDK Solutions

SetBackground

API Information

API Type Description Resource
/slides/{name}/slides/{slideIndex}/background PUT Sets a background for a presentation slide. SetBackground

Request Parameters

Name Type Location Required Description
name string path true The name of a presentation file.
slideIndex integer path true The 1-based index of the slide to set a background.
background object body true The background DTO. For more information, please see the API Reference and look for the SlideBackground object.
password string header false The password to open the presentation.
folder string query false The path to the folder containing the presentation.
storage string query false The name of the storage contaning the folder.

In case of Amazon S3 storage folder path starts with Amazon S3 bucket name.

Background Properties

Name Type Description
Type TypeEnum The background fill type.
FillFormat FillFormat The background fill format.
EffectFormat EffectFormat The background effect format.

Background Types (TypeEnum)

Name Description
Gradient Specifies a gradient fill.
NoFill No fill is applied.
NotDefined No fill is specified. The background is applied from a slide layout.
Pattern Specifies a pattern fill.
Picture Specifies a picture fill.
Solid Specifies the fill to a solid color.

Examples

Set MyImage.png as the background for the second slide in MyFolder/MyPresentation.pptx document saved to the default storage. Use the Tile fill mode.

cURL Solution

SDK Solutions

DeleteBackground

API Information

API Type Description Resource
/slides/{name}/slides/{slideIndex}/background DELETE Deletes the background applied to a presentation slide. DeleteBackground

Request Parameters

Name Type Location Required Description
name string path true The name of a presentation file.
slideIndex integer path true The 1-based index of the slide to delete a background.
password string header false The password to open the presentation.
folder string query false The path to the folder containing the presentation.
storage string query false The name of the storage contaning the folder.

In case of Amazon S3 storage folder path starts with Amazon S3 bucket name.

Examples

Delete a background applied to the second slide in MyFolder/MyPresentation.pptx document saved to the default storage.

cURL Solution

SDK Solutions

SetBackgroundColor

API Information

API Type Description Resource
/slides/{name}/slides/{slideIndex}/backgroundColor PUT Sets a background color for a presentation slide. SetBackgroundColor

Request Parameters

Name Type Location Required Description
name string path true The name of a presentation file.
slideIndex integer path true The 1-based index of the slide.
color string query true The slide background color in #RRGGBB or #AARRGGBB format.
password string header false The password to open the presentation.
folder string query false The path to the folder containing the presentation.
storage string query false The name of the storage contaning the folder.

In case of Amazon S3 storage folder path starts with Amazon S3 bucket name.

Examples

Set the background color to #AABBDD for the first slide in the document MyPresentation.pptx saved in the default storage.

cURL Solution

SDK Solutions

SDKs

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