Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/asp.net/35.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Html 如何在ASPX页面中将米转换为带2位小数的英尺_Html_Asp.net_Converter_Dimensions - Fatal编程技术网

Html 如何在ASPX页面中将米转换为带2位小数的英尺

Html 如何在ASPX页面中将米转换为带2位小数的英尺,html,asp.net,converter,dimensions,Html,Asp.net,Converter,Dimensions,有人能帮我正确显示从米转换的英尺单位吗? 在我的ASPX页面中,我得到了下面的代码。我不知道如何用小数点后的两位数显示脚。我想展示这样的东西:2.067m=6.78 ft 我尝试使用几种格式的结果字符串,例如#.#.#.#.#.#.##.#0,但没有任何效果与我希望的方式相同。你能帮帮我吗 我的网址是。 任何帮助都将不胜感激 <span class='<%# IIf(Double.Parse(Eval("insideLenght"), System.Globalizatio

有人能帮我正确显示从米转换的英尺单位吗? 在我的ASPX页面中,我得到了下面的代码。我不知道如何用小数点后的两位数显示脚。我想展示这样的东西:2.067m=6.78 ft

我尝试使用几种格式的结果字符串,例如#.#.#.#.#.#.##.#0,但没有任何效果与我希望的方式相同。你能帮帮我吗

我的网址是。 任何帮助都将不胜感激

     <span class='<%# IIf(Double.Parse(Eval("insideLenght"), System.Globalization.CultureInfo.InvariantCulture) = 0, "hidden", "col-md-6")%>'>
     <%# Container.DataItem("insideLenght")%> m</span>
     <span class='<%# IIf(Double.Parse(Eval("insideLenght"), System.Globalization.CultureInfo.InvariantCulture) = 0, "hidden", "col-md-6")%>'>
     <%# Convert.ToInt32(Container.DataItem("insideLenght") * 3.2808399000000001).ToString("#.##")%> ft</span>
<span class='<%# IIf(Double.Parse(Eval("insideWidth"), System.Globalization.CultureInfo.InvariantCulture) = 0, "hidden", "col-md-6")%>'>
     <%# Container.DataItem("insideWidth")%> m</span>
     <span class='<%# IIf(Double.Parse(Eval("insideWidth"), System.Globalization.CultureInfo.InvariantCulture) = 0, "hidden", "col-md-6")%>'>
     <%# Convert.ToInt32(Container.DataItem("insideWidth") * 3.2808399000000001).ToString("#.#")%> ft </span>
     <span class='<%# IIf(Double.Parse(Eval("insideHeight"), System.Globalization.CultureInfo.InvariantCulture) = 0, "hidden", "col-md-6")%>'>
     <%# Container.DataItem("insideHeight")%> m</span>

M
英尺
M
英尺
M
“> 英尺 '> M '> 英尺 '> M '>
ft

不确定您想要什么,您能告诉我们您存档了什么吗?您的代码格式也不好,因此很难检测到您做了什么?不知道“归档”是什么意思。我只想正确使用以下标记:ToString(“#.#”)。无论我为结果选择哪种格式,它都不起作用。无论是#.#####还是#.#0或#.#对结果都没有任何影响。我需要2个小数点后的小数点后的结果。这真奇怪,为什么它不工作!我的意思是无论你做了什么,请告诉我们。你的代码不正确,我们怎么能复制我Jacky。你能告诉我代码的哪一部分不正确吗?因为网页上的转换工作正常,如您所见。。