单元格数据不以科学计数法显示
FarPoint.Web.Spread.DoubleCellType DoubleCellType = new FarPoint.Web.Spread.DoubleCellType();int nDecimalDigits =6;
DoubleCellType.MaximumValue = 10000000000;
DoubleCellType.MinimumValue = -10000000000;
FpSpread1.Sheets.Cells.CellType = DoubleCellType;
数据在输入0.000005时以科学计数法显示了,如何设置?
FarPoint.Web.Spread.TextCellType TextCellType = new FarPoint.Web.Spread.TextCellType();下可以,但我输入框有数据类型验证,只能用DoubleCellType 。
我这里没有重现出您的问题,您是就加了一下代码吗
FarPoint.Web.Spread.DoubleCellType DoubleCellType = new FarPoint.Web.Spread.DoubleCellType();
int nDecimalDigits = 6;
DoubleCellType.MaximumValue = 10000000000;
DoubleCellType.MinimumValue = -10000000000;
FpSpread1.Sheets.Cells.CellType = DoubleCellType; 本帖最后由 gsyxy100 于 2017-9-22 09:59 编辑
问题已经解决
FarPoint.Web.Spread.DoubleCellType DoubleCellType = new FarPoint.Web.Spread.DoubleCellType();
int nDecimalDigits = 6;
DoubleCellType.MaximumValue = 10000000000;
DoubleCellType.MinimumValue = -10000000000;
System.Globalization.NumberFormatInfo CellFormat = new System.Globalization.NumberFormatInfo();
CellFormat.NumberDecimalDigits = 6;
DoubleCellType.NumberFormat = CellFormat;
FpSpread1.Sheets.Cells.CellType = DoubleCellType;
数据大时会有千分位,如:666,888,666.258可以去掉千分位符号吗?
设置 NumberGroupSeparator
DoubleCellType.NumberFormat = new System.Globalization.NumberFormatInfo();
DoubleCellType.NumberFormat.NumberGroupSeparator = ""; System.Globalization.NumberFormatInfo nb = new System.Globalization.NumberFormatInfo();
nb.NumberDecimalDigits = 4;
nb.NumberGroupSizes = new int[]{0}; 您好:
请问您的这个问题解决了吗? ClarkPan 发表于 2018-1-9 16:11
您好:
请问您的这个问题解决了吗?
问题已经解决,楼上我有回复你看。 {:4_86:}
页:
[1]