Converting from cultureinfo en-EN to de-DE

Hello friends,

I have a string value “€ 5,506.15” that need to be parsed from en-EN culturinfo to de-DE so it will come out as “5.506,15”. But my compiler is not having it. What am i doing wrong?

What i tried:
value = “€ 5,506.15”
valueNoEuro = value.Replace(“€”,“”)
valueParsed = CDbl.Parse(valueNoEuro, new system.cultureinfo(“de-DE”)

Hi @uiStijn

I think u missed bracket at the end.
Try ths.

valueParsed = CDbl.Parse(valueNoEuro, new system.cultureinfo(“de-DE”))

Check out this thread :Can't convert currency Culture Info

Hope this might help you.

Hello Suraj,

Thank you for the fast reply.

Lets separate double number formats and currencies

“€ 5,506.15” = 5,506.15 = wihtout the currency symbol a double in default format

grafik

1 Like

Hi @uiStijn

Check out this thread :Can't convert currency Culture Info

1 Like

Awesome, thanks again @ppr and @Suraj_B_Shetty

@ppr
Hey Peter,

How would i parse a datatable with this string?

Just let each topic scoped to one case and open a new topic for this question. When opening the new topic please elaborate more on input and expected output as

is not clear.

Also have a look at the following:

myValue = myDataRowVar(ColumnNamrOrIndex).toString.Trim

1 Like

Thank you Peter, will do that.

Alright i’ll try :smiley:

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