Interval Values for Dates and Times ASP Tutorial - ASP Web Pro
  Active Server Pages Programming by ASP Web Pro

ASP Tutorials

INTERVAL VALUES FOR DATES / TIMES

When you work with dates and times, it is vital to know the correct value that represents the date or time period you are wanting. Here is a list of available date / time values:

Value
Meaning
"yyyy"
Year
"q"
Quarter
"m"
Month
"y"
Day of Year
"d"
Day
"w"
Weekday
"ww"
Week of Year
"h"
Hour
"n"
Minute
"s"
Seconds

Here is an example of how this may be used:

<%
Response.Write DateAdd ("d", 1, Date)
%>

This displays tomorrows date like this: 29/08/2008

For other examples, check out our Date scripts on our ASP Scripts page.

< Back to Tutorials


 

 

Main Menu
Home
ASP Scripts
ASP Tutorials
JavaScripts
Awards
Contact Us

Email This Page

Other Resources
ASP Web Hosting
Search Engine Submission
Programming Help

 

 

 

Other ASP Web Sites

Site Map

 

Last Updated:
28 August 2008