When displaying the value of a decimal currently with .ToString()
, it\'s accurate to like 15 decimal places, and since I\'m using it to represent dollars and ce
Given decimal d=12.345; the expressions d.ToString("C") or String.Format("{0:C}", d) yield $12.35 - note that the current culture's currency settings including the symbol are used.
Note that "C" uses number of digits from current culture. You can always override default to force necessary precision with C{Precision specifier}
like String.Format("{0:C2}", 5.123d)
.