Required expertise on Regex

Hi @Sahil_Garg1 ,

For Starters, could you check with the below Regex Expression :

(?<=amount of overpayment:).*?(\d+\s\d+)\s[\d.,]+\s(\d+\s\d+)\s[\d.,]+\s(\d+\s\d+)\s[\d.,]+\s(\d+\s\d+)\s[\d.,]+\s(\d+\s\d+)

We would need to access the required values using Groups.

Debug Panel :

Regex.Match(strText,"(?<=amount of overpayment:).*?(\d+\s\d+)\s[\d.,]+\s(\d+\s\d+)\s[\d.,]+\s(\d+\s\d+)\s[\d.,]+\s(\d+\s\d+)\s[\d.,]+\s(\d+\s\d+)").Groups(1)


Do note that we only received a Single Sample text, the regex expression could also vary for different formats, do check this with multiple samples and confirm if it works or not. For the given format or pattern, the Regex should be good.

1 Like