Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/
Cmdlet

Get-OfficeWordTable

Module
PSWriteOffice
Inputs
OfficeIMO.Word.WordDocument OfficeIMO.Word.WordSection System.String[]
Outputs
OfficeIMO.Word.WordTable

Gets tables, optionally only those with a cell matching a pattern.

Syntax

Get-OfficeWordTable
[-CaseSensitive]
[-Document <WordDocument>]
[-IncludeNested]
[-Pattern <String>]
[-SimpleMatch]
[<CommonParameters>]
#
Parameter set: Document
Get-OfficeWordTable
[-CaseSensitive]
[-IncludeNested]
[-Path] <String[]>
[-Pattern <String>]
[-SimpleMatch]
[<CommonParameters>]
#
Parameter set: Path
Get-OfficeWordTable
[-CaseSensitive]
[-IncludeNested]
-LiteralPath <String[]>
[-Pattern <String>]
[-SimpleMatch]
[<CommonParameters>]
#
Parameter set: LiteralPath
Get-OfficeWordTable
[-CaseSensitive]
[-IncludeNested]
[-Pattern <String>]
-Section <WordSection>
[-SimpleMatch]
[<CommonParameters>]
#
Parameter set: Section

Examples

Example 1

Get-OfficeWordTable -CaseSensitive

Example 2

Get-OfficeWordTable -LiteralPath @('C:\Path')

Example 3

Get-OfficeWordTable -Path @('C:\Path')

Parameters

-CaseSensitive SwitchParameter optional
Use case-sensitive matching.
-Document WordDocument optionalpipeline: True (ByValue)sets: Document
Caller-owned document; omission uses the enclosing Word content block.
-IncludeNested SwitchParameter optional
Include tables nested in cells.
-Pattern String optional
Optional regular expression, or literal text with SimpleMatch.
-SimpleMatch SwitchParameter optional
Treat Pattern as literal text.
-Path String[] requiredposition: 0pipeline: True (ByValue)sets: Path
Document paths; supports wildcards.
-LiteralPath String[] requiredpipeline: True (ByPropertyName)aliases: FullName, PSPathsets: LiteralPath
Exact document paths, including literal brackets.
-Section WordSection requiredpipeline: True (ByValue)sets: Section
Caller-owned section to inspect.

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.