views:

50

answers:

1

Hi, I need to convert a decimal to currency string so i did this:

            CultureInfo usa = new CultureInfo("en-US");
            NumberFormatInfo nfi = usa.NumberFormat;

            nfi.CurrencyDecimalDigits = 0;
            myValueFormated = String.Format(nfi, "{0:C}", value);

It removed decimal places, gave me a comma separator for thousands and and currency symbol. But I also need to display that number in thousands, rounded. Any ideas? Thanks

+1  A: 

You need to do the rounding bit yourself:

value = Math.Round(value / 1000);
Rex M