Ställa in bakgrundsfärgen på huvudbilden
Contents
[
Hide
]
VSTO
PowerPoint.Presentation presentation =
Globals.ThisAddIn.Application.Presentations.Open("Setting Background Color of Master Slide.ppt", Office.MsoTriState.msoFalse, Office.MsoTriState.msoFalse, Office.MsoTriState.msoTrue);
presentation.SlideMaster.Background.Fill.ForeColor.RGB = -654262273;
Aspose.Slides
//Instansiera Presentation-klassen som representerar presentationsfilen
using (PresentationEx pres = new PresentationEx())
{
//Ställ in bakgrundsfärgen för Master ISlide till skogsgrön
pres.Masters[0].Background.Type = BackgroundTypeEx.OwnBackground;
pres.Masters[0].Background.FillFormat.FillType = FillTypeEx.Solid;
pres.Masters[0].Background.FillFormat.SolidFillColor.Color = Color.ForestGreen;
//Skriv presentationen till disk
pres.Save("Setting Background Color of Master Slide.pptx", SaveFormat.Pptx);