In the
preceding section, we saw all but the Last Updated column defined using <ext:Column />
. The Last Updated column was defined using <ext:DateColumn />
. For the other numeric columns, we were happy to deal with them as strings, because the format functions were going to decorate the values with extra HTML anyway. Also, because our ModelField definition inside our Store for these columns had their Type
set to Float
, features such as sorting will be numeric sorting.
If you wanted a formatting specific to numbers, for example, rounding the first Change column to one decimal place, even though the raw data is in two decimal places, you could use NumberColumn
, because its Format
property takes a numeric format to use for display, for example:
<ext:NumberColumn Text="Change" DataIndex="Change" Width="50" Format="0.0" />
BooleanColumn
is also available that lets you set the "True" and "False" text to something else (such as, Yes and No) using the TrueText
and...