Monday, August 30, 2010

WPF, TextBox and currency

Getting data to look right in WPF can be a bit tricky. I wanted integers to appear as currency, but without any decimal points. After a bit of stuffing around I went from:
<TextBox Text="StringFormat=C}" />
to
<TextBox Text="StringFormat=\{0:$###\,##0\}}" />

1 comment: