Project

PSWriteOffice

PowerShell document automation across Word, Excel, PowerPoint, PDF, Reader, Confluence, Visio, and open text formats.

Stars 159
Forks 14
PowerShell Gallery downloads 158,661
Release v3.0.5
Language: C# Updated: 2026-09-03

API Reference

Cmdlet

Rename-OfficePowerPointSection

Namespace PSWriteOffice
Inputs
OfficeIMO.PowerPoint.PowerPointPresentation
Outputs
OfficeIMO.PowerPoint.PowerPointSectionInfo System.Boolean

Renames a PowerPoint section.

Remarks

Renames a PowerPoint section.

Examples

Authored help example

Rename a section in a presentation.

PS>


$ppt = New-OfficePowerPoint -Path .\Examples\Documents\PowerPointRenameSection.pptx -NoSave
            Add-OfficePowerPointSlide -Presentation $ppt -Layout 1
            Add-OfficePowerPointSection -Presentation $ppt -Name 'Results' -StartSlideIndex 0
            Rename-OfficePowerPointSection -Presentation $ppt -Name 'Results' -NewName 'Deep Dive' -PassThru
            $ppt | Close-OfficePowerPoint -Save
        

Renames the first matching section and returns the updated section metadata.

Common Parameters

This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.

For more information, see about_CommonParameters.

Syntax

Rename-OfficePowerPointSection [-CaseSensitive] -Name <String> -NewName <String> [-PassThru] [-Presentation <PowerPointPresentation>] [<CommonParameters>]
#
Parameter set: All Parameter Sets

Parameters

CaseSensitive SwitchParameter optionalposition: namedpipeline: False
Use case-sensitive matching for the existing section name.
Name String requiredposition: namedpipeline: False
Existing section name.
NewName String requiredposition: namedpipeline: False
New section name.
PassThru SwitchParameter optionalposition: namedpipeline: False
Emit the renamed section instead of no output.
Presentation PowerPointPresentation optionalposition: namedpipeline: True (ByValue)
Presentation to update (optional inside DSL).

Outputs

OfficeIMO.PowerPoint.PowerPointSectionInfo, System.Boolean