How can I get text a before a certain string of word using Regex?

Hello,

I am trying to get the text with Regex before specific text. I tried with one expression but it gives me entire line where I want only first one.

Entire String - Összesen 66 1.701,50 181 8.887,33 3.403,57 106,72 12.397,62
Egyéb díjak részletezése Összesen

I want only 12.397,62 which I am trying ti get with Egyéb díjak részletezése Összesen.

Below Expression I have used.
.(?=\sEgyéb díjak részletezése Összesen)

Hi @nilesh.mahajan ,

Maybe you could try the below regex :

[\d\.,]+(?=\sEgyéb díjak részletezése Összesen)

EntireStringVariable.Split({vbLf},StringSplitOptions.RemoveEmptyEntries)(0).Split(" "c).Last
“12.397,62”
You can also use this
thanks

Hi @nilesh.mahajan

Try this-

(\d{1,3}(?:.\d{3})*(?:,\d{2}))

Thanks!!