
Reorganize, encrypt, annotate, and bookmark PDF documents in NET PDF component suite to create, edit, view, print, Multi-format document-processing component suite for. That's it! This article showed how to use the Gnostice StarDocs API to redact text from a PDF document. The below screenshot shows the resultant document being viewed in the StarDocs HTML viewer. If Assigned(DocObjectReceiptRedacted) then Do something with resultant document (redactedFile)

BrushColoringMode := TgtColoringMode.cmUseColor į. := 0 į. := 0 į. := 0 į.Brush.Pattern := bptForwardDiagonal ĭocObjectReceiptRedacted := ( PenColoringMode := TgtColoringMode.cmUseColor į.Pen.Style := pstDash į. := 255 į. := 0 į. := 0 į Regex for matching US telephone numbers

Var searchMode = 'regex' // 'literal' or 'regex' SubRangeMode: 'all' // 'all', 'even', 'odd' Restrict search to given page range only

Var selectedFile = document.getElementById('input').files with an permissions/owner/master password Whether to force full permissions on PDF files protected The below screenshot shows a store receipt containing US telephone numbers being viewed in the StarDocs HTML viewer. We will outline and fill the redacted region with a pattern as well. In this article we'll show you how to redact US phone numbers from a PDF file using a regular expression. The redacted region can be left blank, can be outlined and filled, or a replacement text can written. The search term can either be a literal string or a regular expression. StarDocs provides an easy-to-use API to perform redaction of such text. For example there may be phone numbers, email addresses or Social Security Numbers that you may not want to disclose. However at times there may be pieces of sensitive data in the document that you like to redact (remove or erase) before sharing the document.

PDF files were designed for portability so it's natural that you would share documents in this format. The API reference documentation can be found here. This article builds on the steps explained in those foundational articles to avoid repetition. Select the language for the code snippets If you are new to StarDocs, we suggest you read the introductory article and the getting started article first.
