I'm trying to create a macro in Notepad++ that allows me to do a few standard Search & Replaces. I can get the macro to do everything (add lines, add characters) except search and replace.
I can't find the files to edit the macro manually.
Has anyone ever succeeded creating a Macro in Notepad++ that performs Search and Replace? How?
PS: I'm not interested in other tools that can perform this - I know my way around perl, vi(m), UltraEdit, sed, awk myself - I was just wondering if Notepad++ could do this.
Answer
Yes you can, I just tried to record a new macro, did a search and replace and it successfully saved the action so when I played the macro, it did the same search and replace action.
I am not an expert at Notepad++ Macros, but I am guessing you are... I opened a random file and created a macro called test. It looked for a word called "snip" and replaced it with "blaa".
Opening up the shortcuts.xml
file after closing Notepad++ reveals this new macro:
This is tested and works on my machine, I can manually modify this file and the changes get reflected and work in Notepad++.
Please note however, the shortcuts.xml
file (located in your Appdata folder), only gets loaded and saved on opening/exiting Notepad++.
Comments
Post a Comment