Cmdlet
Get-OfficeWordBookmark
Gets bookmarks from a Word document.
Syntax
Description
Returns WordBookmark objects, optionally filtered by name.
Examples
List report bookmarks by name pattern.
$bookmarks = Get-OfficeWordBookmark -Path .\Report.docx -Name 'Appendix*', 'ExecutiveSummary'
$bookmarks |
Select-Object -Property Name |
Format-Table -AutoSizeLoads the document read-only, filters bookmark names with wildcards, and displays the matching navigation targets.
Parameters
- -Name String[]
- Bookmark name filter (wildcards supported).
- -Path String
- Path to the .docx file.
- -Document WordDocument
- Word document to read.
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.