G
Guest
I've configured a RangeValidator control on a WebForm, using ASP.NET, and
have set the type to string, the max value to 100, and min value to 1,
however, the control to validate always throws an error, regardless of the
length of the string. For example...
<asp:textbox id="txtQuestion" runat="server" Width="400px" MaxLength="100"
Height="50px" TextMode="MultiLine" CssClass="text1"></asp:textbox>
<asp:RangeValidator id="RangeValidatorQuestion1" runat="server"
ControlToValidate="txtQuestion" ErrorMessage="Question length cannot exceed
100 characters." MinimumValue="1" MaximumValue="100">*</asp:RangeValidator>
<asp:Button id="btnSubmit" runat="server" Text="Button"
CausesValidation="true"></asp:Button>
Any ideas why this isn't working? Thanks.
have set the type to string, the max value to 100, and min value to 1,
however, the control to validate always throws an error, regardless of the
length of the string. For example...
<asp:textbox id="txtQuestion" runat="server" Width="400px" MaxLength="100"
Height="50px" TextMode="MultiLine" CssClass="text1"></asp:textbox>
<asp:RangeValidator id="RangeValidatorQuestion1" runat="server"
ControlToValidate="txtQuestion" ErrorMessage="Question length cannot exceed
100 characters." MinimumValue="1" MaximumValue="100">*</asp:RangeValidator>
<asp:Button id="btnSubmit" runat="server" Text="Button"
CausesValidation="true"></asp:Button>
Any ideas why this isn't working? Thanks.