Free Support Forum - aspose.com

Background

Mycoding:

int picId = pres.Pictures.Add(new Picture(pres,MapPath(".")+@"\ShowLetter10.jpg"));
pres.MainMaster.Background.PictureId = picId;
slide.FollowMasterBackground = true;

why doesn’t the background of slide change? it just has white color


Probably you have 2 master slides in a presentation.
In this case MainMaster used for title slides only.

Oh, I’m sorry, vice versa.
MainMaster is for normal slides but you are trying to change title slide.

I’m trying to change background slide, not title slide

“Title Slide” is a type of slides with Title and Subtitle placeholders.

And probably the same problem like in the neighboring thread.

int picId = pres.Pictures.Add(new Picture(pres,MapPath(".")+@"\ShowLetter10.jpg"));
//pres.MainMaster.Background.PictureId = picId;
pres.MainMaster.Background.FillFormat.Type = FillType.Picture;
pres.MainMaster.Background.FillFormat.PictureId = picId;
slide.FollowMasterBackground = true;