I want to take the server date and compare it to two static dates. I want to then be able to manipulate the dates on the dtpicker control.

Here is the code that I have but it does not work... It doesnt go into the if condition. The problem i am trying to solve is on users pcs there is various date formats which affect the date. 12/01/01 on another machine can be 01/12/01... I need to take all dates as one format mm/dd/yy and compare it to the two dates I have specified. If the date is between that period then make the dtpicker1.mindate = 12/01/01



Here is my code
I have an asp page:

I have a text box taking the value of the date

<input id=text1 name=text1 value="<%=Date%>">

then i have :

<script Lanaguage = "vbscript">
sub Window_Onload

Check = text1.value

if Check >= #01/01/01# and Check <= #02/02/01# then
msgbox(Check)
end if

end sub