469,317 Members | 1,957 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,317 developers. It's quick & easy.

Return Server Time + two hours?

In ASP, how can I quickly return the server time + 2 hours, using VBScript?

With TIME(), I've found functions for date arithmetic, but I can't find anything for
time arithmetic.

Thanks!!!


Mar 15 '06 #1
3 1245
Bill wrote:
In ASP, how can I quickly return the server time + 2 hours, using
VBScript?

With TIME(), I've found functions for date arithmetic, but I can't
find anything for time arithmetic.

Thanks!!!

t=dateadd("hh",2,now())
--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.
Mar 15 '06 #2
I changed it to:

t=dateadd("hh",2,time())

and it does what I want, THANKS!!!

"Bob Barrows [MVP]" <re******@NOyahoo.SPAMcom> wrote in message
news:uD**************@TK2MSFTNGP10.phx.gbl...
Bill wrote:
In ASP, how can I quickly return the server time + 2 hours, using
VBScript?

With TIME(), I've found functions for date arithmetic, but I can't
find anything for time arithmetic.

Thanks!!!

t=dateadd("hh",2,now())
--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.

Mar 15 '06 #3

Bill wrote:
I changed it to:

t=dateadd("hh",2,time())

and it does what I want, THANKS!!!


You don't need the date? What happens at 11pm?

Mar 16 '06 #4

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

8 posts views Thread by Ben Allen | last post: by
4 posts views Thread by Peter | last post: by
1 post views Thread by CARIGAR | last post: by
reply views Thread by zhoujie | last post: by
reply views Thread by suresh191 | last post: by
reply views Thread by harlem98 | last post: by
reply views Thread by harlem98 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.