Click or drag to resize
Pdf Library for .NET

PdfRedactionManagerAddRedaction(Regex) Method

Marks every match of a regular expression, on every page, for redaction - for text that follows a pattern rather than a known value, such as account numbers or e-mail addresses. The matches are also taken out of what the document stores without showing it, as for a text.

Namespace: SelectPdf.Universal
Assembly: SelectPdf.Universal (in SelectPdf.Universal.dll) Version: 26.4
Syntax
public void AddRedaction(
	Regex pattern
)

Parameters

pattern  Regex
The expression. Its options decide the letter case (for example IgnoreCase), and \b marks word boundaries.
Remarks
The expression runs over the text of each page as it reads, with words separated by spaces and lines by a space when they continue a sentence, so a match can wrap onto the next line. Typographic quotes read as their plain forms. A match that is empty is ignored.
See Also