简体   繁体   English

当数量很大时如何在datagridview中消除指数格式

[英]how To Get rid of Exponential format in datagridview when the number is very large

When the number is very large like :290754232, I got 2.907542E +08. 当数字非常大时(例如:290754232),我得到了2.907542E +08。 in datagridview cell 在datagridview单元中

I using vb.net , framework 2.0. 我使用的是vb.net,框架2.0。

how can I get rid of this format? 如何摆脱这种格式?

Thanks in advance 提前致谢

Set the default format for the column containing the large number like this: 为包含大量数字的列设置默认格式,如下所示:

myDataGridView.Columns("My Column").DefaultCellStyle.Format = "D"

If you want commas (eg 290,754,232) use "N" instead of "D" 如果要逗号(例如290,754,232),请使用“ N”代替“ D”

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM