views:

164

answers:

2

Hi,

I have two text boxs for time input. I'm trying to compare two time with format : 10:14:23 AM. Then End-TIme must be greater or equal to Start-Time. The ASP.NET CompareValidator doesnt offer the time type, so I'm thinking of using the Customvalidator. I never use Customvalidator to compare the two text boxs for time input before. How to compare the two time? Thank you.

A: 

Have you looked at the MSDN entry for the CustomValidator? It specifies usage and gives an example of how to use it:

Quick Joe Smith
A: 

This was answered here:

http://stackoverflow.com/questions/497294/how-can-i-use-comparevalidator-for-times-without-dates

Although they didn't give any client side validation code, but it should be somewhat similar.

Zach Parrish