I have a asp:rangevalidator control on a textbox that is used to enter the birthdate.
<asp:RangeValidator ID="valrDate" runat="server" ControlToValidate="txtDateOfBirth" MinimumValue="12/31/1950" MaximumValue="1/1/2012" Type="Date" text="Invalid Date" Display="Dynamic"/>
I would really like the ability to change the values of the minimum and maximum based on logic that will throw up a validation notice that indicates the date entered is outside of the allowed range of dates.
Can this be accomplished?
thanks
tony
you can set it in code behind like: