After
When I enter 09:00 start control, and 16:00 in the end; The following code verification fails
Anyone know how I can use the ASP.NET verifier for the time without dates
Start & Lt; ASP:? Text box id = "TxtStart" runat = "server" /> (H: mm) & lt; Br / & gt; Ends & lt; ASP: Textbox ID = "Tuxfinish" Runat = "Server" /> (H: mm) & lt; Br / & gt; & Lt; ASP: CompareValidator ID = "cpvFinish" ControlToValidate = "txtFinish" ControlToCompare = "txtStart" operator = "GreaterThanEqual" type = "date" display = "static" EnableClientScript = "true" errorCare = "time should start after time" " Runat = "server" />
PS- I know that I can easily use CustomValidator, instead it seems like something just should be able to handle this verifier.
This can not be done explicitly.
For the record; I used a custom verifier
Edit :. Here is the case of your custom validator code (ie alhambraeidos) in need of it. Please note that this code is replaced with the name of my sample control (txtStart & amp; txtFinish) with the actual name from my app (txtReady & amp; txtClose)
Try {// Pars & amp; Dates compare to wire randomDt = "01/01/2000"; Args.IsValid = DateTime.parse (randomDt + txtClose.Text) & gt; Date time Purse (random DT + TCTR. Text); } Hold (exception / * ex * /) {// exception is considered invalid time args. IvyValid = false; }
Comments
Post a Comment