Slides.AddSlide Method
PowerPoint Developer Reference |
Creates a new slide, adds it to the Slides collection, and returns the slide.
Syntax
expression.AddSlide(Index, pCustomLayout)
expression An expression that returns a Slides object.
Parameters
Name | Required/Optional | Data Type | Description |
---|---|---|---|
Index | Required | Int | The index of the slide to be added. |
pCustomLayout | Required | CustomLayout | The layout of the slide. |
Return Value
Slide
Example
The following example shows how to use the Add method to add a new slide to the Slides collection. It adds a new slide in index position 2 that has the same layout as the first slide in the active presentation.
Visual Basic for Applications |
---|
|
See Also