Home | Tips | Library | Other Authors | Other WP Sites | Writer's Links | Contact | Site Map | Donate

Barry MacDonnell's
Toolbox for WordPerfect

Macros, tips, and templates for Corel® WordPerfect® for Windows®
© Copyright 1996-2021 by Barry MacDonnell. All Rights Reserved.

Page updated June 17, 2010

The Redactor - Block out (redact) specific text from a document before printing it without affecting the position of the remaining lines of text or the placement of words on a line

Download REDACTOR.ZIP (v2.02; 07/09/08; 21,661 bytes)

Compatible with WordPerfect 9 and later versions

WordPerfect 11 users: See important information about using macros in the first release of WP11 ( at the top of this page.

Downloading, Documentation, Modifications, and Support

Related feature

WordPerfect X4 has a new Redaction Tool (Tools, Redaction). It lets you select some text and mark it for redaction, or automatically search for text throughout the document and mark it in one pass.

When you have finished marking the document with the WPX4 Redactor Tool, a menu item lets you create a separate redacted document in .WPD, .PDF, or .DOC format. The replaced text cannot be retrieved or revealed in the redacted document.


If you decide to use the new built-in Redaction Tool included in the initial release of WordPerfect X4, here are some tips and cautions on using it that were posted on WordPerfect Universe (or get the PDF version).

The information there discusses using normal highlighting (Tools, Highlight) in the same document that is "marked up for redaction" (with WPX4's Tools, Redaction). These issues may be addressed in future releases ("builds") of WPX4 or future major versions, but this is unknown at this point

Note that the Redactor macro (v2.02, downloadable above) uses highlighting, but it will also detect the new redaction codes when it is played in WPX4 or later, and it will warn you to take action to avoid removing any of these Redaction Tool codes.]

More on using the WPX4 Redaction Tool:

It seems that the manual marking process could be speeded up with a macro, which could be assigned to a keystroke combination for fast access during document editing.

The following macro works quickly to do the job. (To copy the macro into your WordPerfect, see here. each command should be on a separate line without hard returns inside any command.)

// Macro code begins here

// Used to manually mark
// selected text for
// redaction in WPX4:

"Select some text first!")


// Macro code ends here

Redactor.wcm is a WordPerfect 9+ macro [for WPX4+ see sidebar] that finds all existing redlined text and -

  • converts redlined text to blacked-out text (using black highlighting), or -
  • applies white color to redlined text to make it appear invisible by blending it with the (normal) white page background, or -
  • completely removes redlined text, and (optionally) clears Undo information to prevent it from being restored later with Edit, Undo.

Important Notes

  • Redlined text: The macro searches for text that is marked with redline attribute codes, not text marked "red" with Document Compare/Review or text that is simply colored red.
    • Use Format, Font, Redline (or the Redline button on some toolbars) to mark selected text before playing the macro. This will result in text that is bracketed with [Redln] codes in Reveal Codes. Redlined text can span multiple pages. (See also the TIPS section below.)
  • The macro preserves the number and location of redacted lines, as well as the absolute beginning and ending positions of the redacted text in the document. This should produce a redacted document of the same length as the original, preserving the overall formatting of the original. The only difference should be the disappearance of the redacted text when the document is printed.
  • Note that the redacted text is not deleted from the document when you choose either of the first two menu choices. Hence if you are concerned about information remaining in the document ("metadata"), you should use the macro to only print the document (in contrast to sharing it with other WordPerfect users).
    • The third menu choice, Rubout, can completely delete the redacted text from the visible body text area, not just mask it. BUT even if you choose Rubout and clear Undo information with the checkbox on the menu, this does not mean that all "metadata" is securely removed from the document. For more on metadata in WordPerfect documents, see here or see "How can I remove metadata from WordPerfect® documents?," which references Answer ID 753605 on Corel's Support Database site at http://support.corel.com.
    • WordPerfect X4 comes with a new Redactor tool. See sidebar at left.
  • The macro will display a dialog after processing all items to remind you to print, remove changes made by the macro (unless you chose to clear Undo levels), or save as a different file to preserve the original file.

Known Limitations

  • If redlined text spans multiple columns, and the last column is a lower-numbered column than the first column (e.g., redline begins in column 3 and ends in column 1 further down in the document), the Rubout menu choice will not be able to process the text properly (but the first two menu choices, Blackout and Whiteout, should work).
  • Redlined text inside table cells might not contain actual redline codes (i.e., [Redln]), and thus the redlined text will not be processed by this macro. The same is true of paragraph styles such as Heading styles, and items included in delay codes, since the [Redln] codes are often "buried" inside them. However, if [Redln] codes are visible in Reveal Codes, the macro should find them and process them.
  • Since the macro's first two menu choices merely mask redacted characters and do not actually remove them, converting the document to a PDF file (with Fiile> Publish to PDF) will not remove the redacted characters internally from the PDF. They could be recovered from the PDF file by a knowledgeable person. However, printing the redacted document on paper will, of course, "remove" the characters from view. Choosing the third menu choice, "Rubout," should do the same thing, since all text is removed from the redacted areas.


  • You can set the initial default menu settings in the User Modification Area in the macro code.
  • Note that your default highlight color is assumed to be bright yellow. This is the color used at the end of the macro's code to reset the highlighting button on the toolbar. If you want a different default color for the highlight button on the toolbar (the program "remembers" which color was last used, so you can always reset the button's default color manually), edit the Red/Green/Blue values in the HighlightColor command under Label(End@).


You can quickly apply the redline font attribute to currently selected text or the word under the cursor with any of the following methods -

  • clicking on Format, Font, Redline.
  • clicking the Font Attribute drop list button on the toolbar (it looks like a lowercase "a"), if present, and checking the redline checkbox.
  • adding a toolbar button for this purpose with Tools, Settings, Customize, Toolbars, <select the toolbar>, Edit, and under the Feature category "Format," scroll down to "Attribute Redline," select it, then click on Add Button. (When the button appeas on the toolbar, it can be dragged to relocate it.) Then click OK, Close to return to the main document window.
  • Instead of adding a toolbar button, assign the redline feature to a keystroke combination by editing the keyboard.
  • Play the QWIKSET macro, which has a redline choice. Or, you can change existing attributes (such as italics or bold) to redline with Ron Hirsch's REPLACE CODES - PLUS macro.
  • See also the Overstrike macro, which "types over" selected text.