Link to home
Start Free TrialLog in
Avatar of franse
franse

asked on

Add hours to system time and show the new time.

Avatar of ASPGuru
ASPGuru

systemtime = now()
hours2add = 4
newtime = dateadd("h",hours2add,systemtime)

response.write newtime


ASPGuru
Avatar of franse

ASKER

ASPGuru,

Sorry the question was not posted when you placed your comment. Cause unknown. I 've tried to fix this by reposting the question.

Can you please specify your answer to the question?

Thanks,

Frans
Avatar of franse

ASKER

Experts,

If someone needs more code please let me know..

Thanks,

Frans
Avatar of franse

ASKER

Experts,

If someone needs more code please let me know..

Thanks,

Frans
you haven't posted another Q...

Just write your Q down here...


ASPGuru
what's your problem actually?
if my code is not what you wanted, specify your problem exactly..

ASPGuru
Avatar of franse

ASKER

Probably to manny characters
I've removed some space and code. Hopefully not to mutch..

sorry,

Frans
ok... so where is it?
also, please maintain your open questions, you still have some old ones.
some experts just ignore questions from people who don't maintain old Qs...

ASPGuru
Avatar of franse

ASKER

Ok again:

A massageboard that will beused in only Holland. And a hosting service with a system time in a other timezone.
I like to add 3 hours to the webserver's time zone to reach the Dutch time zone.
Please use in your answer the code I included in this posting:

-----Code----------------

<table width="80%" cellpadding="2" cellspacing="2" border="0">
     <tr><td><font face="<%=abFont%>" size="-1">Aangemaakt door: <%=adoRs.Fields("author_nameStr").Value%></font></td></tr>    
;      <tr><td><font face="<%=abFont%>" size="-1">;Wanneer: <%=FormatDateTime(adoRs.Fields("msgTime").Value, 2)%>&nbsp;<%=FormatDateTime(adoRs.Fields("msgTime").Value, 3)%></font></td></tr>    
---------end of code--------------
Avatar of franse

ASKER

Ok again:

A massageboard that will beused in only Holland. And a hosting service with a system time in a other timezone.
I like to add 3 hours to the webserver's time zone to reach the Dutch time zone.
Please use in your answer the code I included in this posting:

-----Code----------------

<table width="80%" cellpadding="2" cellspacing="2" border="0">
     <tr><td><font face="<%=abFont%>" size="-1">Aangemaakt door: <%=adoRs.Fields("author_nameStr").Value%></font></td></tr>    
;      <tr><td><font face="<%=abFont%>" size="-1">;Wanneer: <%=FormatDateTime(adoRs.Fields("msgTime").Value, 2)%>&nbsp;<%=FormatDateTime(adoRs.Fields("msgTime").Value, 3)%></font></td></tr>    
---------end of code--------------
ASKER CERTIFIED SOLUTION
Avatar of ASPGuru
ASPGuru

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
and for the second time this:

<%=FormatDateTime(dateadd("h",3,adoRs.Fields("msgTime").Value), 3)%>


ASPGuru
Avatar of franse

ASKER

Thanks it works