Click here to Skip to main content
65,938 articles
CodeProject is changing. Read more.
Articles / programming / regular-expression

Regex to remove someone's overzealous use of regions.

5.00/5 (13 votes)
23 Nov 2009CPOL 31.2K  
A Visual Studio regex to remove someone's overzealous use of regions in VS. Find and replace: (^.*#region.*$)|(^.*#endregion.*$) Remember to enable regular expressions in the Visual Studio find and replace dialog.

A Visual Studio regex to remove someone's overzealous use of regions in VS.

Find and replace: (^.*\#region.*$)|(^.*\#endregion.*$)

 Remember to enable regular expressions in the Visual Studio find and replace dialog.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)