Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Development Tools
 ASP.NET
 custom validator?

Author  Topic 

jhermiz

3564 Posts

Posted - 2009-08-07 : 11:50:07
I need to validate that a date falls right on a sunday.
I dont want to do this on the server side code (page code) as I have to make a trip to the server and find out whether a date falls on a sunday or not.

I tried using a custom validator control as this doesn't involve a post back, but I cannot seem to get this workign the way I want it to.

Anyone know if there is a simple way to determine if the contents of an ASP.net textbox control has a sunday date in it?

Jon


Weblog -- [url]http://weblogs.sqlteam.com/jhermiz[/url]

robvolk
Most Valuable Yak

15732 Posts

Posted - 2009-08-07 : 12:08:44
I'm pretty sure the JavaScript Date object can parse it out:

http://www.w3schools.com/jsref/jsref_obj_date.asp
Go to Top of Page
   

- Advertisement -