由网友(凹凸门先森℡)分享简介:我有一些双值我想转换为字符串,这个模式:I have some double values I want to convert to a string with this pattern:0.xx or x.xx目前我试试这个:double.ToString("#.#0");我应该补充,才能看到零的情况下我的号码...
我有一些双值我想转换为字符串,这个模式:
I have some double values I want to convert to a string with this pattern:
0.xx or x.xx
目前我试试这个:
double.ToString("#.#0");
我应该补充,才能看到零的情况下我的号码从零开始?
What should I add in order to see zero in case my number start with zero?
推荐答案
仅仅使用
myDouble.ToString("0.00")
这是应该做的伎俩
相关推荐
最新文章