仲裁骑士亚托克斯视频:ASP.NET中datagrid 如何设置小数位数?
来源:百度文库 编辑:高校问答 时间:2024/10/03 17:39:35
1、可以在 <asp:HyperLinkColumn> 的 DataTextFormatString 设置 如:
DataTextFormatString = "{0:F}"
DataTextFormatString = "{0:F0}"
DataTextFormatString = "{0:F2}"
例如 123.456 → {0:F2} → 123.46
2、在 <asp:BoundColumn> 则是 DataFormatString 中设置,设置内容同上
使用F,N都可以的,即{0:F2} {0:N2}
有:
1234.567 → {0:F2} → 1234.57
1234.567 → {0:N2} → 1,234.57
就这样,ok了
ASP.NET中datagrid 如何设置小数位数?
ASP.NET中datagrid 如何设置小数位数
asp.net中DataGrid如何传两个不同的参数
asp.net(C#)中DATAGRID问题
在asp.net中如何根据文本框中的日期在datagrid中进行条件查询?谢谢
在asp.net中如何在删除datagrid中的数据时弹出是否删除对话框?
asp.net中关于DataGrid如何删除一行数据的疑问
如何使ASP.NET中DataGrid的排序只排本页,而不是整个数据集全排?
asp.net中datagrid控件 UpdateCommand()怎么写
ASP.NET中如何用DATAGRID控件绑定DROPDIST