The following two lines work fine if the input is correctly specified:
<asp:TextBox ID="MondayOpenTextBox" runat="server" MaxLength="5" /> <Ajax:MaskedEditExtender ID="MondayOpenMaskedEditExtender" runat="server" TargetControlID="MondayOpenTextBox" AcceptAMPM="false" MaskType="Time" Mask="99:99" />
If the user enters "12" and then moves on to the next field, the minutes are filled with the current minute. This is not desirable for this page. I would like to either display an error message or fill in "00" for the missing numbers.
It does not help:
<asp:RegularExpressionValidator runat="server" ID="ValidateMondayOpenTextBox" ControlToValidate="MondayOpenTextBox" Display="Dynamic" ErrorMessage="X" ValidationExpression="\d\d:\d\d" />
since the field is apparently formatted by the time the validator gets its turn on it.
source share