正文
解决 aspx 页面 TextBox 不支持 type="number"
小程序:扫一扫查出行
【扫一扫了解最新限行尾号】
复制小程序
【扫一扫了解最新限行尾号】
复制小程序
安装 framework 4 并且打上补丁Microsoft .NET Framework 4 可靠性更新 1 (KB2533523)
https://www.microsoft.com/zh-cn/download/details.aspx?id=27014
我没有试,但跟据下面的结果来看,安装 4.5应该是可以解决的.
<!-- this HTML tested in each .NET version -->
<asp:TextBox runat="server" type="number" />
Here are the results:<!-- ASP.NET 2.0, 3.0, and 3.5 -->
<input name="ctl01" type="text" type="number" /><!-- ASP.NET 4.0 and 4.5 -->
<input name="ctl01" type="number" />