PDA

Click to See Complete Forum and Search --> : Decimal seperator


Saitn
Apr 4th, 2007, 10:25 AM
Hi,

I'm in a norwegian computer and we use a comma as our decimal seperator, however I need StreamWriter to use a dot instead when I write to a file. I'm outputting some data to a CSV file and the comma on float numbers messes up the fields in the CSV.

Is there any easy way to change the decimal seperator? I can't change the CSV seperator, it has to be a comma.

RohanWest
Apr 4th, 2007, 07:18 PM
You could try this

Thread.CurrentThread.CurrentCulture.NumberFormat.NumberDecimalSeparator = "."