Xceed Workbooks for .NET v2.0 Documentation
PredefinedNumberFormatId Property (Style)


Xceed.Workbooks.NET Assembly > Xceed.Workbooks.NET Namespace > Style Class : PredefinedNumberFormatId Property
Gets or sets the predefined number format with an Id. Built-in common formatting options exist, like in MS Excel. A specific Id can be set to format the content of a Cell, the Cells in a Column or the Cells in a Row with predefined formats. The default value is 0. Setting this property will overwrite the CustomFormat property.
Syntax
'Declaration
 
Public Property PredefinedNumberFormatId As Integer
'Usage
 
Dim instance As Style
Dim value As Integer
 
instance.PredefinedNumberFormatId = value
 
value = instance.PredefinedNumberFormatId
public int PredefinedNumberFormatId {get; set;}
Remarks

Here is the list of the predefined formats Id that can be set:

ID FormatCode
0 General
1 0
2 0.00
3 #,##0
4 #,##0.00
9 0%
10 0.00%
11 0.00E+00
12 # ?/?
13 # ??/??
14 mm-dd-yy
15 d-mmm-yy
16 d-mmm
17 mmm-yy
18 h:mm AM/PM
19 h:mm: ss AM/ PM
20 h:mm
21 h:mm:ss
22 m/d/yy h:mm
37 #,##0 ;(#,##0)
38 #,##0 ;[Red](#,##0)
39 #,##0.00;(#,##0.00)
40 #,##0.00;[Red](#,##0.00)
45 mm:ss
46 [h]:mm:ss
47 mmss.0
48 ##0.0E+0
49 @

 

Requirements

Target Platforms: Windows 11, Windows 10, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

Style Class
Style Members