API Reference

Cmdlet

Get-OfficePdfInfo

Namespace PSWriteOffice
Inputs
System.String
Outputs
OfficeIMO.Pdf.PdfDocumentInfo

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

Authored help example

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 Sets

Parameters

Password String optionalposition: namedpipeline: False
Password used to inspect a Standard password-encrypted PDF.
Path String requiredposition: 0pipeline: True (ByValue)aliases: FilePath
PDF file path.

Outputs

OfficeIMO.Pdf.PdfDocumentInfo