regex - Regular expression to get all matches in string ends with -


please me develop regular expression return matches in string if end (&any character) eg. string a="abcd(&w)", matches should have value (&w) if a="abcd(&w), xhz(&d), there should 2 matches note: in place of comma (,) above can delimiter list [','':',';'.........]

if abcd(&w)pqrsr, xhz(&d). matches should (&d) , not (&w) since not in end before delimiter

something should work:

\(&.\)(?=[,:;]|$) 

this match literal (& followed character, followed literal ). requires next character 1 of ,, :, or ; or match followed end of string.


Comments

Popular posts from this blog

Line ending issue with Mercurial or Visual Studio -

tags - Jquery Mixitup plugin help prevent handlers being destroyed -

c# - Delving into the world of XML (Windows Phone) Error I dont understand (The ' ' character, hexadecimal value 0x20, cannot be included in a name.) -