Cmdlet
Get-OfficeWordParagraph
Gets paragraphs from a Word document or section.
Syntax
Examples
Extract visible paragraph text.
$paragraphs = Get-OfficeWordParagraph -Path .\Report.docx
$paragraphs |
Where-Object { $_.Text } |
Select-Object -Property Text |
Set-Content -Path .\ReportParagraphs.txtEnumerates document paragraphs and writes their text for a lightweight review workflow.
Parameters
- -Path String
- Path to the document.
- -Document WordDocument
- Document to inspect.
- -Section WordSection
- Section to enumerate.
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.