How to remove currency from end of String

Hi All,

I have amount with the currency, e.g. 100,00 EUR. I would like get only 100,00.
How to remove " EUR".

Thanks!

@Krzysztof,

Currency = “100,000 EUR”

Try this one: RequriedResult = Currency.split(" ".TocharArray)(0)

You can use string split function on space. It can be “100,000 EUR”.Split(Cchar(" ")) and assign it to a variable of type array of strings. The first element of the array will be ur result.

1 Like

Hi,
Or you can try using string.replace function like this stringTest.Replace(“EUR”,“”)

or if you have number of type of currencies you can add those to array and then inside for loop you can iterate to get only the digits excluding currency.

Regards,
Pavan H

As I see, this solution works:
str.Substring(0, str.Length-4)
But there is problem to count column “Kwota”. Counting “Kwota1” is ok. Could you check where is the problem?
example.zip (9.7 KB)