SectionProperties.AddBeforeSlide Method (PowerPoint)

Adds a section immediately before the specified slide index, and returns the index of the new section.


expression. AddBeforeSlide( _SlideIndex_, _sectionName_ )

expression A variable that represents a SectionProperties object.


Name Required/Optional Data Type Description
SlideIndex Required Integer The index of the slide before which to add the section.
sectionName Required String The name of the new section.

Return Value



The indices of sections after the newly inserted section are automatically incremented by one.

If a section break exists immediately before the specified slide index, the new section is placed after the section break, with the result that the preceding section is now empty, and the specified slide index is now the first slide of the new section.

If the presentation does not contain any sections and you call this method, passing a SlideIndex value greater than 1, a new section is created before the first slide and given the default section name.

See also

SectionProperties Object