Jus*_*ins 4 c#
我有一个时间跨度显示如下:7.43053333333333.我的目标是简单地将其显示为7.43.
7.43053333333333
7.43
如何在小数位后截断两个第二个值.我尝试使用Math.Round而不是截断,但它会简单地返回7
Math.Round
7
BRA*_*mel 9
只是用 Math.Round Method (Decimal, Int32)
Math.Round Method (Decimal, Int32)
double d = 7.43053333333333; double ma = Math.Round(d, 2);
归档时间:
11 年,9 月 前
查看次数:
2811 次
最近记录: