- Free Printables
- Kids & Teens
- Author Tips
- About Us
Improve your Finds with Workarounds
Something to remember when executing a Replace All is that a mindless computer is doing the work. First rule of Global Replace is to test before clicking Replace All. Enter the Find and Replace items as explained below, then click Find and check that you found what you expected to find. If yes, click Replace and confirm that the replacement is what you want. Repeat this a number of times to assure yourself that nothing unexpected is found.
Another testing method is to use the Find feature. Click Find and use the Navigation box that appears on the left of the screen.
The test below for her is an example.
This find for the word her also finds whether, there, and either. This shows the danger of Replace All or a global replace. In this case, a Find for her, Replace with his would result in Whethis, thise, and eithisr.
But every occurrence of her alone which is the object of the Find is preceded by a space and followed by either a space, comma, period, or some other punctuation mark.
This is a good indication that a global Find for space her space and Replace with space his space could be done safely. This could be followed by a Find for space her period. And then by a Find for space her comma. This would Replace most of the her with his. Following up with a Find for space her would find the remaining her to be fixed and they could be fixed manually.
This is just an example of how you can modify what you want to find for that will exclude finding things you do not want to change.
You can include many codes or hidden characters in your find string as well as characters. When you open the Replace box, click More, then check the dropdown Special at the bottom of the window for a list of the hidden characters or codes that you can include in your find. When using Replace All, remember if you Find for a code or hidden character, it will be replaced with what you put in the Replace box. So if you do not want to lose the code or hidden character, put it in the Replace box just as it is in the Find box.
For example, if you Find for space Paragraph Mark, to remove any spaces before Paragraph Marks, be sure to Replace with Paragraph Mark. If you Replace with nothing, all the paragraph breaks will be lost.
The most important rule to follow when using global Find and Replace - Replace All - is to save the file before executing the replace and to test it manually prior to clicking Replace All. And to keep using the backup plan.
Anything not clear? Please let us know.