API Reference
ConvertTo-OfficePdfRedacted
Applies explicit or text-matched PDF redactions and writes a new PDF.
Remarks
Applies explicit or text-matched PDF redactions and writes a new PDF.
Examples
Apply a redaction rectangle.
PS>
ConvertTo-OfficePdfRedacted -Path .\Report.pdf -OutputPath .\Report-Redacted.pdf -PageNumber 1 -X 72 -Y 650 -Width 240 -Height 32
Removes matching text objects and annotations in the rectangle, then paints a redaction mark.
Redact logical text blocks containing a value.
PS>
ConvertTo-OfficePdfRedacted -Path .\Report.pdf -OutputPath .\Report-Redacted.pdf -Text 'Account number'
Finds matching logical text blocks, removes their content, and paints the derived areas.
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
ConvertTo-OfficePdfRedacted [-FillColor <String>] -Height <Double> [-IgnorePermissionRestrictions] [-Label <String>] [-OnlyPaintMatches] -OutputPath <String> -PageNumber <Int32> [-Password <String>] -Path <String> -Width <Double> -X <Double> -Y <Double> [<CommonParameters>]#RectangleParameters
- FillColor String
- Redaction fill color. Named colors and hexadecimal values are accepted. Defaults to black.
- Height Double
- Rectangle height in PDF points.
- IgnorePermissionRestrictions SwitchParameter
- After successful password authentication, explicitly ignore owner-imposed modification restrictions.
- Label String
- Optional redaction area label.
- OnlyPaintMatches SwitchParameter
- Paint only areas that match text or annotations in the redaction plan.
- OutputPath String
- Output PDF path.
- PageNumber Int32
- One-based page number for the redaction rectangle.
- Password String
- Password used to read a Standard password-encrypted PDF.
- Path String
- Input PDF path.
- Width Double
- Rectangle width in PDF points.
- X Double
- Left coordinate in PDF points.
- Y Double
- Bottom coordinate in PDF points.
Outputs
System.IO.FileInfo
ConvertTo-OfficePdfRedacted -Area <PdfRedactionArea[]> [-FillColor <String>] [-IgnorePermissionRestrictions] [-OnlyPaintMatches] -OutputPath <String> [-Password <String>] -Path <String> [<CommonParameters>]#AreaParameters
- Area PdfRedactionArea[]
- One or more pre-created OfficeIMO.Pdf redaction areas.
- FillColor String
- Redaction fill color. Named colors and hexadecimal values are accepted. Defaults to black.
- IgnorePermissionRestrictions SwitchParameter
- After successful password authentication, explicitly ignore owner-imposed modification restrictions.
- OnlyPaintMatches SwitchParameter
- Paint only areas that match text or annotations in the redaction plan.
- OutputPath String
- Output PDF path.
- Password String
- Password used to read a Standard password-encrypted PDF.
- Path String
- Input PDF path.
Outputs
System.IO.FileInfo
ConvertTo-OfficePdfRedacted [-FillColor <String>] [-IgnorePermissionRestrictions] [-MatchCase] [-OnlyPaintMatches] -OutputPath <String> [-Password <String>] -Path <String> -Text <String[]> [<CommonParameters>]#TextParameters
- FillColor String
- Redaction fill color. Named colors and hexadecimal values are accepted. Defaults to black.
- IgnorePermissionRestrictions SwitchParameter
- After successful password authentication, explicitly ignore owner-imposed modification restrictions.
- MatchCase SwitchParameter
- Use case-sensitive literal text matching.
- OnlyPaintMatches SwitchParameter
- Paint only areas that match text or annotations in the redaction plan.
- OutputPath String
- Output PDF path.
- Password String
- Password used to read a Standard password-encrypted PDF.
- Path String
- Input PDF path.
- Text String[]
- Literal text used to derive redaction areas from matching logical text blocks.
Outputs
System.IO.FileInfo