Clipboard Tools – Paste Replace Word
Once you have a word (identifier) on the clipboard, you can easily replace any different word (identifier) with the one on the clipboard using Ctrl+B shortcut. The Paste Replace CodeRush action will select the word (identifier) at the caret before pasting in the contents of the clipboard, so you don’t have to select it first.
Here is an example. Consider that we have the Location property, which should be returning the default “Unknown” value, but currently it returns null. Let’s see how the Paste Replace Word feature will be useful here:
- Put the editor caret on the “Unknown” word
- Press Ctrl+C to copy it into the Clipboard, using another Smart Copy clipboard feature
- Put the editor caret on the “null” keyword
- Press Ctrl+B to replace the keyword:
—– Products: CodeRush Pro, CodeRush Xpress Versions: 10.1 and up VS IDEs: any Updated: Feb/02/2011 ID: C044