How to repeat a search followed by editing text?
I used the record macro function to record myself doing Ctrl + h to search for "[a-z]/[a-z]" (a / that is preceded and followed by any alphabetic character) and then used the arrow keys to move the cursor and insert spaces either side of the /, without overwriting the alphabetic characters that become highlighted in the search.
What I'm struggling with is how to repeat this action for the rest of the document? I want to search, then edit text, then search again, etc, until the end of the document. The search function alone just does the search, and if I use the search and replace function, because the alphabetic characters are highlighted in the search, replacement text overwrites those characters, which I don't want. I feel like there's some basic loop command or something but I can't find any examples of code that are similar enough to what I want, and I've tried and tested a few different approaches with no luck.
Thanks.
|