Get Started
Documentation

CreateBlipFill

CreateBlipFill(sImageUrl, sBlipFillType) → {ApiFill}

Create a blip fill which allows to fill the object using a selected image as the object background.

Parameters:

Name Type Description
sImageUrl string The path to the image used for the blip fill (currently only internet URL or Base64 encoded images are supported).
sBlipFillType BlipFillType The type of the fill used for the blip fill (tile or stretch).

Returns:

Type
ApiFill

Example

Copy code
builder.CreateFile("pptx");
var oPresentation = Api.GetPresentation();
var oSlide = oPresentation.GetSlideByIndex(0);
oFill = Api.CreateBlipFill("https://api.onlyoffice.com/content/img/docbuilder/examples/icon_DocumentEditors.png", "tile");
oSlide.SetBackground(oFill);
builder.SaveFile("pptx", "CreateBlipFill.pptx");
builder.CloseFile();

Resulting document