Quantcast
Channel: AutoIt v3 - General Help and Support
Viewing all articles
Browse latest Browse all 12506

Regex expression problem

$
0
0
I have a problem here with Regex,

If I were to use this expression


$arr = StringRegExp("STARTblablablaaENDblabSTARTlabENDlabSTARTblablaEND","START([a-z|A-Z]*)END",3)


Regex will return only one match, which will contain everything between the first "START" and the last "END"

I do not know how (if it is possible) to tell regex what I know: That between "START" and "END" there will never be the phrase "START" or "END"! but it doesn't know that, because it's only matching any alphabetical character.....

I need to return an array that would have each match separate like this: "blablablaa", "lab", "blabla".

The above expression was just an example, in my actual string it would be all uppercase. But I have tested this above expression and it performs exactly as my program does... Is there any possible way to tell it to match everything except a certain phrase?

Viewing all articles
Browse latest Browse all 12506

Trending Articles