Cmdlet
Add-OfficePdfStamp
Stamps text, images, native canvas content or a PDF page onto existing PDFs.
Syntax
Add-OfficePdfStamp
[-Behind]
[-Color <OfficeColor>]
[-Document <PdfDocument>]
[-Opacity <Double>]
[-Page <OfficePageSelector>]
[-PassThru]
[-Rotation <Double>]
[-Size <OfficeLength>]
-Text <String>
[-X <OfficeLength>]
[-Y <OfficeLength>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]#Parameter set:
TextDocumentAdd-OfficePdfStamp
[-Behind]
[-Color <OfficeColor>]
[-IgnorePermissionRestrictions]
[-LoadOptions <PdfLoadOptions>]
[-Opacity <Double>]
-OutputPath <String>
[-Page <OfficePageSelector>]
[-PassThru]
[-Password <SecureString>]
[-Path] <String[]>
[-Rotation <Double>]
[-Size <OfficeLength>]
-Text <String>
[-X <OfficeLength>]
[-Y <OfficeLength>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]#Parameter set:
TextAdd-OfficePdfStamp
[-Behind]
[-Color <OfficeColor>]
[-IgnorePermissionRestrictions]
[-LoadOptions <PdfLoadOptions>]
[-Opacity <Double>]
-OutputDirectory <String>
[-Page <OfficePageSelector>]
[-PassThru]
[-Password <SecureString>]
[-Path] <String[]>
[-Rotation <Double>]
[-Size <OfficeLength>]
-Text <String>
[-X <OfficeLength>]
[-Y <OfficeLength>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]#Parameter set:
TextDirectoryAdd-OfficePdfStamp
[-Behind]
[-Height <OfficeLength>]
[-IgnorePermissionRestrictions]
-ImagePath <String>
[-LoadOptions <PdfLoadOptions>]
[-Opacity <Double>]
-OutputPath <String>
[-Page <OfficePageSelector>]
[-PassThru]
[-Password <SecureString>]
[-Path] <String[]>
[-Rotation <Double>]
[-Width <OfficeLength>]
[-X <OfficeLength>]
[-Y <OfficeLength>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]#Parameter set:
ImageAdd-OfficePdfStamp
[-Behind]
[-Height <OfficeLength>]
[-IgnorePermissionRestrictions]
-ImagePath <String>
[-LoadOptions <PdfLoadOptions>]
[-Opacity <Double>]
-OutputDirectory <String>
[-Page <OfficePageSelector>]
[-PassThru]
[-Password <SecureString>]
[-Path] <String[]>
[-Rotation <Double>]
[-Width <OfficeLength>]
[-X <OfficeLength>]
[-Y <OfficeLength>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]#Parameter set:
ImageDirectoryAdd-OfficePdfStamp
[-Behind]
[-ConfigureRendering <ScriptBlock>]
-Content <ScriptBlock>
[-IgnorePermissionRestrictions]
[-LoadOptions <PdfLoadOptions>]
[-Opacity <Double>]
-OutputPath <String>
[-Page <OfficePageSelector>]
[-PassThru]
[-Password <SecureString>]
[-Path] <String[]>
[-Rotation <Double>]
[-X <OfficeLength>]
[-Y <OfficeLength>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]#Parameter set:
ContentAdd-OfficePdfStamp
[-Behind]
[-ConfigureRendering <ScriptBlock>]
-Content <ScriptBlock>
[-IgnorePermissionRestrictions]
[-LoadOptions <PdfLoadOptions>]
[-Opacity <Double>]
-OutputDirectory <String>
[-Page <OfficePageSelector>]
[-PassThru]
[-Password <SecureString>]
[-Path] <String[]>
[-Rotation <Double>]
[-X <OfficeLength>]
[-Y <OfficeLength>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]#Parameter set:
ContentDirectoryAdd-OfficePdfStamp
[-Behind]
[-Fit <Contain| Cover| Stretch>]
[-Height <OfficeLength>]
[-HorizontalAlignment <OfficeAlignment>]
[-IgnoreOverlayPermissionRestrictions]
[-IgnorePermissionRestrictions]
[-LoadOptions <PdfLoadOptions>]
[-Opacity <Double>]
-OutputPath <String>
[-OverlayLoadOptions <PdfLoadOptions>]
[-OverlayPage <Int32>]
[-OverlayPassword <SecureString>]
-OverlayPath <String>
[-Page <OfficePageSelector>]
[-PassThru]
[-Password <SecureString>]
[-Path] <String[]>
[-Rotation <Double>]
[-VerticalAlignment <Top| Center| Bottom>]
[-Width <OfficeLength>]
[-X <OfficeLength>]
[-Y <OfficeLength>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]#Parameter set:
PageAdd-OfficePdfStamp
[-Behind]
[-Fit <Contain| Cover| Stretch>]
[-Height <OfficeLength>]
[-HorizontalAlignment <OfficeAlignment>]
[-IgnoreOverlayPermissionRestrictions]
[-IgnorePermissionRestrictions]
[-LoadOptions <PdfLoadOptions>]
[-Opacity <Double>]
-OutputDirectory <String>
[-OverlayLoadOptions <PdfLoadOptions>]
[-OverlayPage <Int32>]
[-OverlayPassword <SecureString>]
-OverlayPath <String>
[-Page <OfficePageSelector>]
[-PassThru]
[-Password <SecureString>]
[-Path] <String[]>
[-Rotation <Double>]
[-VerticalAlignment <Top| Center| Bottom>]
[-Width <OfficeLength>]
[-X <OfficeLength>]
[-Y <OfficeLength>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]#Parameter set:
PageDirectoryAdd-OfficePdfStamp
[-Behind]
[-Color <OfficeColor>]
[-IgnorePermissionRestrictions]
-LiteralPath <String[]>
[-LoadOptions <PdfLoadOptions>]
[-Opacity <Double>]
-OutputPath <String>
[-Page <OfficePageSelector>]
[-PassThru]
[-Password <SecureString>]
[-Rotation <Double>]
[-Size <OfficeLength>]
-Text <String>
[-X <OfficeLength>]
[-Y <OfficeLength>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]#Parameter set:
TextLiteralPathAdd-OfficePdfStamp
[-Behind]
[-Height <OfficeLength>]
[-IgnorePermissionRestrictions]
-ImagePath <String>
-LiteralPath <String[]>
[-LoadOptions <PdfLoadOptions>]
[-Opacity <Double>]
-OutputPath <String>
[-Page <OfficePageSelector>]
[-PassThru]
[-Password <SecureString>]
[-Rotation <Double>]
[-Width <OfficeLength>]
[-X <OfficeLength>]
[-Y <OfficeLength>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]#Parameter set:
ImageLiteralPathAdd-OfficePdfStamp
[-Behind]
[-ConfigureRendering <ScriptBlock>]
-Content <ScriptBlock>
[-IgnorePermissionRestrictions]
-LiteralPath <String[]>
[-LoadOptions <PdfLoadOptions>]
[-Opacity <Double>]
-OutputPath <String>
[-Page <OfficePageSelector>]
[-PassThru]
[-Password <SecureString>]
[-Rotation <Double>]
[-X <OfficeLength>]
[-Y <OfficeLength>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]#Parameter set:
ContentLiteralPathAdd-OfficePdfStamp
[-Behind]
[-Fit <Contain| Cover| Stretch>]
[-Height <OfficeLength>]
[-HorizontalAlignment <OfficeAlignment>]
[-IgnoreOverlayPermissionRestrictions]
[-IgnorePermissionRestrictions]
-LiteralPath <String[]>
[-LoadOptions <PdfLoadOptions>]
[-Opacity <Double>]
-OutputPath <String>
[-OverlayLoadOptions <PdfLoadOptions>]
[-OverlayPage <Int32>]
[-OverlayPassword <SecureString>]
-OverlayPath <String>
[-Page <OfficePageSelector>]
[-PassThru]
[-Password <SecureString>]
[-Rotation <Double>]
[-VerticalAlignment <Top| Center| Bottom>]
[-Width <OfficeLength>]
[-X <OfficeLength>]
[-Y <OfficeLength>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]#Parameter set:
PageLiteralPathAdd-OfficePdfStamp
[-Behind]
[-Color <OfficeColor>]
[-IgnorePermissionRestrictions]
-LiteralPath <String[]>
[-LoadOptions <PdfLoadOptions>]
[-Opacity <Double>]
-OutputDirectory <String>
[-Page <OfficePageSelector>]
[-PassThru]
[-Password <SecureString>]
[-Rotation <Double>]
[-Size <OfficeLength>]
-Text <String>
[-X <OfficeLength>]
[-Y <OfficeLength>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]#Parameter set:
TextLiteralPathDirectoryAdd-OfficePdfStamp
[-Behind]
[-Height <OfficeLength>]
[-IgnorePermissionRestrictions]
-ImagePath <String>
-LiteralPath <String[]>
[-LoadOptions <PdfLoadOptions>]
[-Opacity <Double>]
-OutputDirectory <String>
[-Page <OfficePageSelector>]
[-PassThru]
[-Password <SecureString>]
[-Rotation <Double>]
[-Width <OfficeLength>]
[-X <OfficeLength>]
[-Y <OfficeLength>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]#Parameter set:
ImageLiteralPathDirectoryAdd-OfficePdfStamp
[-Behind]
[-Document <PdfDocument>]
[-Height <OfficeLength>]
-ImagePath <String>
[-Opacity <Double>]
[-Page <OfficePageSelector>]
[-PassThru]
[-Rotation <Double>]
[-Width <OfficeLength>]
[-X <OfficeLength>]
[-Y <OfficeLength>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]#Parameter set:
ImageDocumentAdd-OfficePdfStamp
[-Behind]
[-ConfigureRendering <ScriptBlock>]
-Content <ScriptBlock>
[-IgnorePermissionRestrictions]
-LiteralPath <String[]>
[-LoadOptions <PdfLoadOptions>]
[-Opacity <Double>]
-OutputDirectory <String>
[-Page <OfficePageSelector>]
[-PassThru]
[-Password <SecureString>]
[-Rotation <Double>]
[-X <OfficeLength>]
[-Y <OfficeLength>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]#Parameter set:
ContentLiteralPathDirectoryAdd-OfficePdfStamp
[-Behind]
[-ConfigureRendering <ScriptBlock>]
[-Content] <ScriptBlock>
[-Document <PdfDocument>]
[-Opacity <Double>]
[-Page <OfficePageSelector>]
[-PassThru]
[-Rotation <Double>]
[-X <OfficeLength>]
[-Y <OfficeLength>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]#Parameter set:
ContentDocumentAdd-OfficePdfStamp
[-Behind]
[-Fit <Contain| Cover| Stretch>]
[-Height <OfficeLength>]
[-HorizontalAlignment <OfficeAlignment>]
[-IgnoreOverlayPermissionRestrictions]
[-IgnorePermissionRestrictions]
-LiteralPath <String[]>
[-LoadOptions <PdfLoadOptions>]
[-Opacity <Double>]
-OutputDirectory <String>
[-OverlayLoadOptions <PdfLoadOptions>]
[-OverlayPage <Int32>]
[-OverlayPassword <SecureString>]
-OverlayPath <String>
[-Page <OfficePageSelector>]
[-PassThru]
[-Password <SecureString>]
[-Rotation <Double>]
[-VerticalAlignment <Top| Center| Bottom>]
[-Width <OfficeLength>]
[-X <OfficeLength>]
[-Y <OfficeLength>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]#Parameter set:
PageLiteralPathDirectoryAdd-OfficePdfStamp
[-Behind]
[-Document <PdfDocument>]
[-Fit <Contain| Cover| Stretch>]
[-Height <OfficeLength>]
[-HorizontalAlignment <OfficeAlignment>]
[-IgnoreOverlayPermissionRestrictions]
[-Opacity <Double>]
[-OverlayLoadOptions <PdfLoadOptions>]
[-OverlayPage <Int32>]
[-OverlayPassword <SecureString>]
-OverlayPath <String>
[-Page <OfficePageSelector>]
[-PassThru]
[-Rotation <Double>]
[-VerticalAlignment <Top| Center| Bottom>]
[-Width <OfficeLength>]
[-X <OfficeLength>]
[-Y <OfficeLength>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]#Parameter set:
PageDocumentExamples
Example 1
Add-OfficePdfStamp -Text 'Value'Example 2
Add-OfficePdfStamp -Path @('C:\Path') -OutputPath 'C:\Path' -Content { }Example 3
Add-OfficePdfStamp -Path @('C:\Path') -OutputDirectory 'Value' -Content { }Parameters
- -Behind SwitchParameter
- Place the stamp behind existing page content.
- -Color OfficeColor
- Native Color setting for the stamp.
- -Document PdfDocument
- Caller-owned PDF; omission uses the enclosing editing block.
- -Opacity Double
- Native Opacity setting for the stamp.
- -Page OfficePageSelector
- Native one-based page selector, including last, odd and even.
- -PassThru SwitchParameter
- Return the saved FileInfo or the updated live document.
- -Rotation Double
- Native Rotation setting for the stamp.
- -Size OfficeLength
- Text size; omission keeps the native 24-point default.
- -Text String
- Literal text to stamp.
- -X OfficeLength
- Native X setting for the stamp.
- -Y OfficeLength
- Native Y setting for the stamp.
- -WhatIf SwitchParameter
- Shows what would happen if the command runs.
- -Confirm SwitchParameter
- Prompts for confirmation before running the command.
- -IgnorePermissionRestrictions SwitchParameter
- After authentication, explicitly ignore owner-imposed restrictions.
- -LoadOptions PdfLoadOptions
- Native input parsing, authentication and resource policy.
- -OutputPath String
- Single output PDF file.
- -Password SecureString
- Source PDF password.
- -Path String[]
- Input PDF files with FileSystem wildcard expansion.
- -OutputDirectory String
- Output folder retaining source file names.
- -Height OfficeLength
- Native Height setting for the stamp.
- -ImagePath String
- Literal image file to stamp.
- -Width OfficeLength
- Native Width setting for the stamp.
- -ConfigureRendering ScriptBlock
- Configure native rendering options for the canvas callback.
- -Content ScriptBlock
- Native canvas callback receiving the canvas and target page context.
- -Fit PdfPageOverlayFit
- Native Fit setting for the stamp.
- Possible values:
Contain,Cover,Stretch - -HorizontalAlignment OfficeAlignment
- Native HorizontalAlignment setting for the stamp.
- Possible values:
Left,Center,Right,Justify,Start,End - -IgnoreOverlayPermissionRestrictions SwitchParameter
- After overlay authentication, explicitly ignore owner-imposed restrictions.
- -OverlayLoadOptions PdfLoadOptions
- Native loading policy for the imported overlay PDF.
- -OverlayPage Int32
- One-based page imported from the overlay PDF.
- -OverlayPassword SecureString
- Password for the imported overlay PDF.
- -OverlayPath String
- Literal PDF file whose selected page is imported.
- -VerticalAlignment OfficeTextVerticalAlignment
- Native VerticalAlignment setting for the stamp.
- Possible values:
Top,Center,Bottom - -LiteralPath String[]
- Literal PDF files, including FileInfo.FullName.
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.