Regex-Getting total and subtotal

Hi
I need to get the value of Subtotal from this"Moneda: MXN SubTotal 17,770.00"
and total from this “Total MXN 20,613.20”. Can anyone please help me with the Regex

Hi @abivanth.r

(?<=SubTotal\s+).*

(?<=Total MXN\s+).*

Regards

Hi @abivanth.r

image

image

Cheers!!

Thanks bro!!
Worked…

1 Like

You’re welcome bro @abivanth.r

happy Automation!!

Hi @abivanth.r ,

System.Text.RegularExpressions.Regex.Match("Moneda: MXN SubTotal 17,723470.00","[\d,]+\.\d+").Value

This will work for both strings.

Regards,
Vinit Mhatre

:heart:
Thanks a lot bro!!!

1 Like

Thanks bro!!
working :partying_face:

1 Like

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