This content is for v4.x (Alpha). Switch to the Stable version.
Slide Class Overview
Section titled βSlide Class OverviewβThe Slide
class, a vital component of the OpenXMLOffice.Presentation
library, serves as a versatile tool for manipulating individual slides within a PowerPoint presentation. Whether extracted from an existing presentation or added new, this class provides a convenient handle for developers to modify the content of a single slide.
Key Features
Section titled βKey Featuresβ- Content Manipulation: The
Slide
class facilitates the addition of various elements to a slide, including charts, tables, and text. Developers can seamlessly enhance the visual richness of the presentation by incorporating diverse content types. - Integration with PowerPoint Templates: This class seamlessly integrates with existing PowerPoint templates, allowing developers to maintain a consistent look and feel throughout the presentation.
Example Usage
Section titled βExample Usageβusing OpenXMLOffice.Presentation;
public static SlideManipulation(Slide slide, DataCell[][] DataCells, AreaChartSetting AreaChartSetting){ // Add New Chart To the Slide // Follow chart document for more info Chart chart = slide.AddChart(DataCells, AreaChartSetting); // To Add picture to the slide Picture picture = slide.AddPicture("sample.jpg", PictureSetting PictureSetting); // To Add Table Table table = slide.AddTable(DataCells, TableSetting TableSetting); // To Find a shape based on text from PPTX Shape shape = slide.FindShapeByText("shape_id");}
Slide Setting Object for slide options
- Background
- Header/Footer
- Size
- Border, etcβ¦