例如。
Math.Round(2.314, 2) //2.31 Math.Round(2.301, 2) //2.3 , but I want this as 2.30
发布于 2013-10-23 16:26:18
2.3和2时30分是一回事。如果您想要字符串2时30分,那么对.ToString函数使用Math.Round (“F2”)。
https://stackoverflow.com/questions/19547138
相似问题