How to find certain syntax in a string?

Dear community,

I got a question: I have a long string and want to find the position of a certain syntax with the letter “f” and four random numbers e.g “f1234”. The “f” will be there everytime, but the numbers change. So it’s like “fxxxx”. Is there any option?

Thank you!!

If there’s only one in a larger string MyString, you can find it by assigning a new string variable to System.Text.RegularExpressions.Regex.Match(MyText, "f\d{4}").Value.

2 Likes

Hi @Jonathan_Langer

So you can use the below thing to find the string
image

Mark as solution and like it :slight_smile:

Happy Automation :raised_hands:

Best Regards
Er Pratik Wavhal :robot::man_technologist:t4: :computer:

Thank you very much, Robot Master!! You made my day!

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