Question regarding REGEX

I am reading all the data from a PDF, I want to find a string example “Tax ID: RO874231” from it using Regex.

The one which I am using is “(?<=Tax\sID)\d+”. It does not work
Please let me know the correct regex


Try below Regex expression.

          (?<=Tax ID: )\w+

1 Like

have a look on a more defensive pattern. The matched value we can later trim

1 Like

Thanks it works

it works thanks


You should Mark the correct post as solution but not yours :sweat_smile:

sorry. Both the answers worked for me. Anyway to mark both as solution?

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