Hi @Amit,

Thanks for your response ,  There is a change in the ask  I would like to get a regex to capture a word from the string if it  has only digits/digits+letters/letters+digits/. Is it possible 

For example

var str1= "this is a test r11MS0AB8;  // output is r11MS0AB8

var str 2 = ""this is a test  123Abc12CD";  // output is 123Abc12CD

var str3 = "this is a test 51571008";  // output is 51571008

Is it possible to create a regex to show the above output. Thanks in advance