DLL
To format a number cell
-
If you want to display the separator character and use the regional default characters used to display the thousands separator and the decimal character, call the SSSetTypeNumber function.
If you want to format the cell in any of the following ways, call the SSSetTypeNumberEx function.
- Display a leading zero in values between 1.0 and –1.0
- Specify the format characters used to display the thousands separator and the decimal character
- Specify the format of negative numeric values
Set the parameters for the functions as follows:- Set the LeadingZero parameter to SS_LEADING_ZERO_NO to display values between 1.0 and –1.0 without a leading zero.
- Set the Separator parameter to specify a custom separator character and set the ShowSeparator parameter to TRUE.
- Set the Decimal parameter to specify a custom decimal symbol.
- Set the NegCurrencyStyle to specify the format for negative values.
- Call the SSSetCellType or SSSetCellTypeRange function and set the CellType parameter to SS_TYPE_NUMBER.