TypeNumberLeadingZero Property
Applies To
fpSpread control
Description
Sets or returns whether a leading zero displays in a number cell. This property is available at run time only.
Syntax
long CSpreadSheet::GetTypeNumberLeadingZero( );
void CSpreadSheet::SetTypeNumberLeadingZero(long value);
[form.]fpSpread.TypeNumberLeadingZero[ = setting%]
Remarks
When the TypeNumberLeadingZero property is set to 2 (Yes), number cells display a leading zero for values less than 1.0 and greater than –1.0, for example, "0.21".
The following settings are available:
Setting | Description | Constants |
---|---|---|
0 - Intl | (Default) Uses the regional setting for Number Format in the Windows Control Panel | TypeLeadingZeroIntl |
1 - No | Removes the leading zero | TypeLeadingZeroNo |
2 - Yes | Displays the leading zero | TypeLeadingZeroYes |
Notes:
|
To use the TypeNumberLeadingZero property, specify the sheet with which you want to work by setting the Sheet property. Then specify the cell or cells to which to apply the property, as described in Using Column and Row Properties. Once you set the TypeNumberLeadingZero property for a cell or cells, any subsequent number cells you create will use the same TypeNumberLeadingZero setting unless you reset it for those cells.
The TypeNumberLeadingZero property does not have an effect unless the CellType property is set to 13 (Number) for the specified cell or cells.
Spread Designer
Choose the Cell menu, the Cell Type menu, the Number menu, and then the Settings tab, and then select an item in the Leading Zero drop-down list box in the Cell Type Settings dialog box.
Data Type
Integer (Enumerated)
See Also
Variations in Windows Regional Settings or Options
Formatting a Currency Cell
CellType, Sheet, TypeNumberDecimal, TypeNumberDecPlaces, TypeNumberMax, TypeNumberMin, TypeNumberNegStyle, TypeNumberSeparator, TypeNumberShowSep properties
DLL Correspondence
SSSetTypeNumberEx function