KnowDotNet NetRefactor

Regular Expressions

Regular Expressions, found in the System.Text.RegularExpressions namespace, can be used to parse, extract information from, and modify strings of text.  They are a very powerful tool for pattern matching, going far beyond the LIKE statements of VisualBasic or SQL.


Articles  

Convert Stored Proc to Dynamic SQL -
How do I use the Clipboard in a Macro? It does not appear to work. And I want to convert a Stored Procedure to Dynamic SQL.    more...

Convert VB6 to VB.NET -
Macros, in combination with Regular Expressions form a powerful tool set for generating code. This article will generate a Input Line Object from a VB6 Type Object.    more...

Regex for Comma Delimited Text -
Need to parse a truly comma delimited text line? It is not easy without the use of regular expressions.    more...

Using a MatchEvaluator with Regex.Replace -
The regular expression engine in .NET is obviously a powerful alternative to traditional String manipulation methods when dealing with complex parsing or validation. The power of the Regex.Replace method allows the developer to perform replacements based on patterns rather than literal text. Beyond this, though, .NET Regex offers an even more powerful tool - the MatchEvaluator.    more...

Combining Regular Expressions and RichTextBox Methods to Parse Code -
You can combine the use of Regular Express and RichTextBox functionality to locate the occurrence of expressions in a string and capture the line number of the lines containing the expressions.    more...

Parsing with Regular Expressions - Counting Leading Spaces in a String -
Is there a function to count the number of leading spaces in a line of text. This is a valuable function when parsing and indenting source code.    more...

Parsing with Regular Expressions - All-Alpha-Character String -
Is there a function in .NET that will determine if all characters in a string are Alpha?    more...

Parsing with Regular Expressions - IsDigit -
How can I easily tell if the first character of a string is numeric?    more...

Using Regular Expressions to Create Parsing Methods -
Is there a function to tell if all characters in a string are numeric?    more...

Using Regular Expressions - Replacing VB6 Replace -
The use of the VB6 Replace function should be replaced with RegEx.Replace for several reasons.    more...


plus 6 more...

Writing Add-Ins for Visual Studio .NET
Writing Add-ins for Visual Studio .NET
by Les Smith
Apress Publishing