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

Get-OfficeWordShape

Aliases: WordShapes
Namespace PSWriteOffice
Aliases
WordShapes
Inputs
OfficeIMO.Word.WordDocument OfficeIMO.Word.WordParagraph OfficeIMO.Word.WordSection
Outputs
OfficeIMO.Word.WordShape

Gets shapes from a Word document, section, or paragraph.

Remarks

Gets shapes from a Word document, section, or paragraph.

Examples

Authored help example

List shapes and metadata.

PS>


$shapes = Get-OfficeWordShape -Path .\Report.docx
            $shapes |
                Select-Object -Property Title, Description, Width, Height, FillColorHex |
                Format-Table -AutoSize
        

Reads OfficeIMO Word shapes from the document so styling and alternate text can be audited.

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

Get-OfficeWordShape -Path <String> [<CommonParameters>]
#
Parameter set: Path

Parameters

Path String requiredposition: 0pipeline: Falsealiases: FilePath, InputPath
Path to the document.

Outputs

OfficeIMO.Word.WordShape

Get-OfficeWordShape -Document <WordDocument> [<CommonParameters>]
#
Parameter set: Document

Parameters

Document WordDocument requiredposition: namedpipeline: True (ByValue)
Document to inspect.

Outputs

OfficeIMO.Word.WordShape

Get-OfficeWordShape -Section <WordSection> [<CommonParameters>]
#
Parameter set: Section

Parameters

Section WordSection requiredposition: namedpipeline: True (ByValue)
Section to inspect.

Outputs

OfficeIMO.Word.WordShape

Get-OfficeWordShape -Paragraph <WordParagraph> [<CommonParameters>]
#
Parameter set: Paragraph

Parameters

Paragraph WordParagraph requiredposition: namedpipeline: True (ByValue)
Paragraph to inspect.

Outputs

OfficeIMO.Word.WordShape