<td> Date of Birth <span style="color:Red;">*</span></td>
<td>
<asp:TextBox ID="txt_dob" runat="server" CssClass="form-control" required="" x-moz-errormessage="Enter Date of Birth"
placeholder="Date of Birth"></asp:TextBox>
<cc1:CalendarExtender ID="txt_calender" runat="server" Format="dd/MM/yyyy" TargetControlID="txt_dob">
</cc1:CalendarExtender>
<asp:CompareValidator ID="cfvDOB" ForeColor="Red" ControlToValidate="txt_dob" Type="Date" Operator="LessThan"
ErrorMessage="(Age can't be less than 15 years)" Display="Dynamic" ValidationGroup="Save2"
runat="server"></asp:CompareValidator>
<asp:RequiredFieldValidator ID="reqval" runat="server" ValidationGroup="Save2" ErrorMessage="Enter Date of Birth" ForeColor="Red" ControlToValidate="txt_dob">
</asp:RequiredFieldValidator>
</td>
No comments:
Post a Comment