Problem with currency formats and big numbers [on hold]
- by user132750
I am working on a dollars to euros/euros to dollars converter in C#. I got the formula, $ times 0.73361 = euro, and I have checked Google with the answers. They were right, (1 dollar equals 0.73 euros). However, it stops working properly when the dollar input value is higher than $1363. This is what I get with $1364: $1364 = 1 000,64 €. I don't know what to do, will someone please help me?
Thanks.
decimal toEuro;
Val.doy = "$" + decimal.Parse(richTextBox1.Text); //Ignore this, it's for the output form
CultureInfo eu = new CultureInfo("fr-FR");
toEuro = decimal.Parse(richTextBox1.Text.Trim());
toEuro = toEuro * 0.73361m;
richTextBox1.Clear();
Val.duh = toEuro.ToString("C2", eu);