Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
8680
Validate WebDateTimeEdit using RequiredFieldValidator
posted

I would like to use an <asp:RequiredFieldValidator> to validate a WebDateTimeEdit.  Can anyone provide and example of how this is done?

TIA

Parents
  • 24497
    Suggested Answer
    posted

    Hi Ed,

    It can be used by exactly same way as for a TextBox. Example:

    <igtxt:WebDateTimeEdit ID="WebDateTimeEdit1" runat="server"></igtxt:WebDateTimeEdit>
    <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server"
         ControlToValidate="WebDateTimeEdit1" ErrorMessage="RequiredFieldValidator"></asp:RequiredFieldValidator>

Reply Children