Thursday 22 October 2015

Multiline regex selection in visual studio

As a .net developer i always use visual studio IDE with shortcuts keys and inbuilt functionality. To replace find and replace i always use Regex. I was thinking that regex with multiple line would be more complex, but isn't. I use simple code and its work for me.

Steps:

  1. Press ctrl + shift + f
  2. Find option > Use Regular Expression
  3. Find


Regex Syntax

startexpression.*(.*\n)+?.*endexpression