|
Extract all quoted strings with the RegExp object
|
Total Hit (3699) |
When parsing a text file that contains quoted strings - such as a VB source file - you might want to quickly locate and extract all the quoted strings. Thanks to regular expressions and the RegExp object in the Microsoft VBScript Regular Expression type library, this task is surprisingly easy:
«co
....Read More |
Rating
|
|
|
Extract words with the RegExp object
|
Total Hit (3818) |
The following routine extracts all the words from a source string and returns a collection. Optionally, the result contains only unique words.
This code is remarkably simpler than an equivalent "pure" VB solution because it takes advantage of the RegExp object in the Microsoft VBScript Regular Expr
....Read More |
Rating
|
|
|
Search multiple substrings with the RegExp object
|
Total Hit (3855) |
The RegExp object in the Microsoft VBScript Regular Expression type library supports regular expression patterns containing the | (or) operator, which lets you search for multiple substrings at the same time. For example, the following piece of code lets you search for a month name in a source text:
....Read More |
Rating
|
|
|
Count number of words with the RegExp object
|
Total Hit (3845) |
A Visual Basic function that counts the number of words in a sentence or text file can become quickly very complex, and usually doesn't execute fast enough for most purposes. Thanks to the RegEx object that comes with the Microsoft VBScript Regular Expression type library, this task becomes trivial.
....Read More |
Rating
|
|
|
Create a better InStr function with VBScript regular expressions
|
Total Hit (15285) |
Regular expressions offer an extremely powerful way to search and replace text inside a string using sophisticated search criteria, far behind the capabilities of VB's InStr and Replace functions. For example, you can search for whole words, or find a match with a range of characters (for example, a
....Read More |
Rating
|
|
|
|
|
|
Create your own Image/Link extractor tool using Regular Expressions
|
Total Hit (3281) |
This is a very simple code to present use of Regular expression to solve some complex text operation which is kinda impossible using inbuilt string functions available in Visual Basic.
For More information Visit the following MSDN article
«a href='http://msdn.microsoft.com/library/en-us/dnclin
....Read More |
Rating
|
|