Visual Studio 2010 Gallery - RegEx Editor
Regular expressions provide a concise and flexible means for identifying strings of text, such as particular characters, words, or patterns of characters. A regular expression is a special text string for describing a search pattern.
For example, the following RegEx will validate a USA telephone number with the format of "1-NNN-NNN-NNNN"
"^1?\s*-?\s*(\d{3}|\(\s*\d{3}\s*\))\s*-?\s*\d{3}\s*-?\s*\d{4}$"
So, in this example, a value of "1-800-555-1212" will pass; "555-1212" will fail.
Now, you can the ability to develop and test your Regex expressions INSIDE Visual Studio 2010. It’s and one of the many, many awesome extensions provided for our latest IDE. Here is a screen shot of the editor:
This sample was built to ease your pain when working with regular expressions. It rehosts the editor in a dialog box and provides a basic language service to provide colorization, brace matching, sample testing grouping and selection tracking. It shows re-hosting of the editor in a tool window, and provides a nice starting point for similar projects.
Check it out at: https://visualstudiogallery.msdn.microsoft.com/en-us/55c24bf1-2636-4f94-831d-28db8505ce00
Technorati Tags: Visual Studio 2010
Comments
Anonymous
December 14, 2010
No way to find how this extension works. There is no button to popup the app, neither the app popup when im writing the regular expression. :(Anonymous
January 04, 2011
Same here ... didn't figured out how to use it yetAnonymous
January 04, 2011
same here... didn't figured out yet how to use it.Anonymous
February 22, 2011
The comment has been removedAnonymous
August 15, 2011
Is there another way to get the editor? It won't pop up in my installation of vs2010. I think it collides with another installed extension. So why not have a button or some kind of hotkey?Anonymous
August 15, 2011
Okay. Here is the solution. Add a new Regex("D"); to the SourceCode, and then CTRL+Click the "D" - the editor will pop up. But there's still a problem preventing me from using it: The tool can handle a German / or other key board layout - I can't add any braces as I normally would. That's sad, because the tool seems to be pretty cool.