这是我正在使用的代码,但是当我运行该代码时,即使我将值放在范围内,它也会显示一条错误消息。请有人帮我解决这个问题吗?
<tr>
<td class="auto-style4">Password</td>
<td class="auto-style3">
<asp:TextBox ID="Pass" runat="server"></asp:TextBox>
</td>
<td>
<asp:RequiredFieldValidator ID="RequiredFieldValidator8" runat="server" ControlToValidate="Pass" ErrorMessage="Please enter Password" ForeColor="Red"></asp:RequiredFieldValidator>
<br />
<asp:RangeValidator ID="RangeValidator1" runat="server" ControlToValidate="Pass" Display="Dynamic" ErrorMessage="Password range (1 -10)" ForeColor="Red" MaximumValue="10" MinimumValue="1"></asp:RangeValidator>
</td>
</tr>