API Reference
Cmdlet
Get-OfficePdfInfo
Gets PDF metadata, page information, forms, links, and structural flags.
Remarks
The returned OfficeIMO.Pdf inspection object is useful for validating generated artifacts, migration scripts, and existing PDFs before follow-up operations such as splitting, stamping, or metadata updates.
Examples
Inspect a generated PDF.
PS>
$info = Get-OfficePdfInfo -Path .\Report.pdf
$info.PageCount
$info.LinkUris
Reads page count and link information from the PDF.
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-OfficePdfInfo [-Password <String>] -Path <String> [<CommonParameters>]#Parameter set:
All Parameter SetsParameters
- Password String
- Password used to inspect a Standard password-encrypted PDF.
- Path String
- PDF file path.
Outputs
OfficeIMO.Pdf.PdfDocumentInfo