API Reference
Get-OfficeWordStatistics
Gets document statistics from a Word document.
Remarks
Returns a PowerShell-friendly snapshot of OfficeIMO.Word statistics for quick reporting and validation.
Examples
Check document complexity before publishing.
PS>
$stats = Get-OfficeWordStatistics -Path .\Report.docx
$stats |
Select-Object -Property Paragraphs, Tables, Images, Charts |
Format-List
Reads OfficeIMO.Word statistics and displays the structural counts that matter for a release artifact.
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-OfficeWordStatistics -InputPath <String> [<CommonParameters>]#PathParameters
- InputPath String
- Path to the Word document.
Outputs
PSWriteOffice.Models.Word.WordDocumentStatisticsInfo: PowerShell-friendly snapshot of Word document statistics.
Get-OfficeWordStatistics -Document <WordDocument> [<CommonParameters>]#DocumentParameters
- Document WordDocument
- Document to inspect.
Outputs
PSWriteOffice.Models.Word.WordDocumentStatisticsInfo: PowerShell-friendly snapshot of Word document statistics.