AD
Administrator
Syncfusion Team
July 1, 2004 06:13 AM UTC
You can set grid.TableStyle.Format to control how numeric CellValueTypes are displayed. Some sample format strings you could try are "F", "F4", "#.###", "0.000", "#.0000", or "#.#####################".
Now the number of significant digits displayed will conform to the the Type, roughly 7 digits for floats and 14-15 digits for doubles. So, if your user types 10 significant digits into a float cell, then he will lose some of the significance when the string value inputted is converted to a float value for storing, and the display will be affected. If you do not want this, then I think you would have to change the CellValueType to string, and the formatting would not be applied (as style.Format only affects non-string CellValueTypes).