Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/
Cmdlet

Get-OfficePdfAttachment

Module
PSWriteOffice
Inputs
OfficeIMO.Pdf.PdfDocument System.String[]
Outputs
OfficeIMO.Pdf.PdfExtractedAttachment System.IO.FileInfo

Lists embedded files, or extracts them with -OutputDirectory.

Syntax

Get-OfficePdfAttachment
[-IgnorePermissionRestrictions]
[-LoadOptions <PdfLoadOptions>]
[-Name <String>]
[-NoClobber]
[-OutputDirectory <String>]
[-Password <SecureString>]
[-Path] <String[]>
[-WhatIf]
[-Confirm]
[<CommonParameters>]
#
Parameter set: Path
Get-OfficePdfAttachment
[-IgnorePermissionRestrictions]
-LiteralPath <String[]>
[-LoadOptions <PdfLoadOptions>]
[-Name <String>]
[-NoClobber]
[-OutputDirectory <String>]
[-Password <SecureString>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
#
Parameter set: LiteralPath
Get-OfficePdfAttachment
-Document <PdfDocument>
[-Name <String>]
[-NoClobber]
[-OutputDirectory <String>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
#
Parameter set: Document

Examples

Example 1

Get-OfficePdfAttachment -Path @('C:\Path')

Example 2

Get-OfficePdfAttachment -Document 'Value'

Example 3

Get-OfficePdfAttachment -LiteralPath @('C:\Path')

Parameters

-IgnorePermissionRestrictions SwitchParameter optionalsets: Path, LiteralPath
IgnorePermissionRestrictions for PDF inspection or extraction.
-LoadOptions PdfLoadOptions optionalsets: Path, LiteralPath
LoadOptions for PDF inspection or extraction.
-Name String optional
Name for PDF inspection or extraction.
-NoClobber SwitchParameter optional
NoClobber for PDF inspection or extraction.
-OutputDirectory String optional
OutputDirectory for PDF inspection or extraction.
-Password SecureString optionalsets: Path, LiteralPath
Password for PDF inspection or extraction.
-Path String[] requiredposition: 0sets: Path
Path for PDF inspection or extraction.
-WhatIf SwitchParameter optional
Shows what would happen if the command runs.
-Confirm SwitchParameter optional
Prompts for confirmation before running the command.
-LiteralPath String[] requiredpipeline: True (ByPropertyName)aliases: FullName, PSPathsets: LiteralPath
LiteralPath for PDF inspection or extraction.
-Document PdfDocument requiredpipeline: True (ByValue)sets: Document
Document for PDF inspection or extraction.

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.