Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/
Cmdlet

Get-OfficePdfRedactionPlan

Module PSWriteOffice
Inputs
System.String
Outputs
OfficeIMO.Pdf.PdfRedactionPlan

Previews explicit or text-matched PDF redaction areas before content is removed.

Syntax

Get-OfficePdfRedactionPlan -Height <Double> [-IgnorePermissionRestrictions] [-Label <String>] -PageNumber <Int32> [-Password <String>] [-Path] <String> -Width <Double> -X <Double> -Y <Double> [<CommonParameters>]
#
Parameter set: Rectangle
Get-OfficePdfRedactionPlan -Area <PdfRedactionArea[]> [-IgnorePermissionRestrictions] [-Password <String>] [-Path] <String> [<CommonParameters>]
#
Parameter set: Area
Get-OfficePdfRedactionPlan [-IgnorePermissionRestrictions] [-MatchCase] [-Password <String>] [-Path] <String> -Text <String[]> [<CommonParameters>]
#
Parameter set: Text

Description

This command reports redaction impact only. It does not remove or rewrite PDF content.

Examples

Authored help example

Preview a redaction rectangle.

Get-OfficePdfRedactionPlan -Path .\Report.pdf -PageNumber 1 -X 72 -Y 650 -Width 240 -Height 32

Returns line-level text blocks and annotations that intersect the rectangle.

Find content to redact by text.

Get-OfficePdfRedactionPlan -Path .\Report.pdf -Text 'Account number'

Derives reviewable redaction areas from logical text blocks containing the supplied text.

Parameters

-Height Double requiredsets: Rectangle
Rectangle height in PDF points.
-IgnorePermissionRestrictions SwitchParameter optional
After successful password authentication, explicitly ignore owner-imposed extraction restrictions.
-Label String optionalsets: Rectangle
Optional redaction area label.
-PageNumber Int32 requiredsets: Rectangle
One-based page number for the redaction rectangle.
-Password String optional
Password used to read a Standard password-encrypted PDF.
-Path String requiredposition: 0pipeline: True (ByValue)aliases: FilePath
PDF file path.
-Width Double requiredsets: Rectangle
Rectangle width in PDF points.
-X Double requiredsets: Rectangle
Left coordinate in PDF points.
-Y Double requiredsets: Rectangle
Bottom coordinate in PDF points.
-Area PdfRedactionArea[] requiredsets: Area
One or more pre-created OfficeIMO.Pdf redaction areas.
-MatchCase SwitchParameter optionalsets: Text
Use case-sensitive literal text matching.
-Text String[] requiredsets: Text
Literal text used to derive redaction areas from matching logical text blocks.

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.