top of page

Use Notepad ++ to Change Strings Specified in Regex String


It's possible to run find and replace RegEx searches in Notepad ++ that include the searched for strings in the replacement with new data. So for example, if you have a list of street addresses and you want to add in separators, you can do the following:

1. Press CTRL + H to bring up the find and replace tool and select the Regular Expression mode.

2. Enter this RegEx search in the Find box:

(AL|AK|AZ|AR|CA|CO|CT|DE|DC|FL|GA|HI|ID|IL|IN|IA|KS|KY|LA|ME|MD|MA|MI|MN|MS|MO|MT|NE|NV|NH|NJ|NM|NY|NC|ND|OH|OK|OR|PA|RI|SC|SD|TN|TX|UT|VT|VA|WA|WV|WI|WY|AS|GU|MP|PR|VI|UM) ([0-9][0-9][0-9][0-9][0-9])

[note the the pipes are 'OR' operators in Regex searches.]

3. In the replace box enter:

~ \1~ \2

4. After you click, Replace All, your data will have tildes in front of the state abbreviations and the zip codes.


 
 

Recent Posts

See All
How does Relativity use AI data?

How is data generated by aiR utilized by Relativity? Relativity has published a white paper addressing its AI security policies assuring...

 
 

Sean O'Shea has more than 20 years of experience in the litigation support field with major law firms in New York and San Francisco.   He is an ACEDS Certified eDiscovery Specialist and a Relativity Certified Administrator.

​

The views expressed in this blog are those of the owner and do not reflect the views or opinions of the owner’s employer.

​

If you have a question or comment about this blog, please make a submission using the form to the right. 

Your details were sent successfully!

© 2015 by Sean O'Shea . Proudly created with Wix.com

bottom of page