Get a text following pattern

Hi masters, please I need clue getting the text starting with MON and ending with TECH from this string
“PRES credit 00000786 as MON98734521TECH”
the statement is dynamic but the word starting with MON doesn’t change only the digit changes

give a try on regex
grafik
Alternate:
grafik

1 Like

Hi @stanstilo,
Using @ppr expressions
u can try assigning it to a variable and will get the required output

System.Text.RegularExpressions.Regex.Matches(str,"(MON\d+TECH)")(0).Value

“str” is input string type variable

Regards,
Shaf

1 Like

When I use .Value it throws an error value is not a member of char

HI @stanstilo

Instead of Value, you can use ToString

Here is the workflow it will help you
Dummy.xaml (5.4 KB)

Hope it will work

Regards
Gokul

1 Like

Thanks Gokul

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.