I'm trying to make a RegExp match for any text that is in between '<<<' and '>>>' However, I am unable to do this unless there is a carriage return within the string being evaluated by the Regular Expression object. For example, if I evaluate the following string, I will only get a match on the first instance of text between '<<<' and '>>>' per line:
Type: <<<Type>>>
If Type = "Professional Liability" then enter <<<Occurance>>> and <<<Aggregate>>>
I get a match for 'Type' and 'Occurance', but NOT for 'Aggregate'
Here is the code I am using:
'Create Regualar Expression Object
Set objRE = New RegExp
'objRE.Pattern = "<<<[\s\S].[^>]*>>>" 'to match <<< >>> tags and contents
objRE.Global = True
'Get all matches for any text within special character Set objMatches = objRE.Execute(description)
I can't figure out why I only get one match per line. I have spent hours trying to figure this out and have researched several web sites regarding RegExp thorougly.
Please advise...I would greatly appreciate any help or ideas.
Thanks,
-Brett
Type: <<<Type>>>
If Type = "Professional Liability" then enter <<<Occurance>>> and <<<Aggregate>>>
I get a match for 'Type' and 'Occurance', but NOT for 'Aggregate'
Here is the code I am using:
'Create Regualar Expression Object
Set objRE = New RegExp
'objRE.Pattern = "<<<[\s\S].[^>]*>>>" 'to match <<< >>> tags and contents
objRE.Global = True
'Get all matches for any text within special character Set objMatches = objRE.Execute(description)
I can't figure out why I only get one match per line. I have spent hours trying to figure this out and have researched several web sites regarding RegExp thorougly.
Please advise...I would greatly appreciate any help or ideas.
Thanks,
-Brett