Jul-10-2017, 07:10 PM
I use the code below through Notepad++ but I cannot make it match whole words
with open('C:/Temp/Substitutions.txt') as f: for l in f: s = l.split() editor.replace(s[0], s[1])I also tried:
editor.pyreplace(r'\b' + s[0] + r'\b', s[1])and
editor = re.sub(r'\b' + s[0] + r'\b', s[1], editor)