ofcourse its datediff<BR><BR>but you could have framed your sentence in a nicer way, probably a request cos no one here works for you...its an forum where people help each other with their ideas and thoughts.<BR><BR>Hope I am not being rude.
Example:<BR><BR><%<BR>newYearsDay = #1/1/2005#<BR><BR>Response.Write "There are still " & ( newYearsDay - Date() ) & " days in 2004."<BR>%><BR><BR>Yes, DateDiff is more elegant. And if one or both of your variables have both date *AND* time stored in them, it's a better thing to use.<BR><BR>But for date-only values, you can subtract to get difference in days. And you can simply add an integer to a date to get another date:<BR><BR><%<BR>Response.Write "10 days from now is " & (Date() + 10)<BR>%><BR>
...but I didn't see that in his message.<BR><BR>He said<BR> Can some one tell me a quick way ...<BR><BR>I read that to mean he wanted a short and easy answer instead of a long convoluted one. (I suspect that he was envisioning having to do it all by hand...counting days in each month or some such ugly stuff.)<BR><BR>Anyway, obviously DATEDIFF is not a wrong answer. Heck, it's actually the only right answer if one or both the values include a time component. My "double duh" was just me hassling you for the fun of it. Sorry.<BR><BR>Here's a fun one to try:<BR><BR><%= Now() - Date() %><BR><BR>
I really did mean to try it. <BR><BR>More fun:<BR><BR><%<BR>Response.Write "diff: " & ( Now() - Date() ) & "<P>" <BR>Response.Write "time as double: " & CDbl( Time() )<BR>%><BR><BR>Quiz for today: Explain the results.<BR><BR>