ASP/VBScript CDate() Returns an expression that has been converted to a Variant of subtype Date.
ShotDev Focus:
- Using Asp and CDate() function.
Example
asp_cdate.asp
<% Option Explicit %> <html> <head> <title>ShotDev.Com Tutorial</title> </head> <body> <% Response.write CDate("12/12/2010")&"<br>" Response.write CDate("1 Mar 2010")&"<br>" Response.write CDate("Apr 5 2010")&"<br>" Response.write CDate("31/08/2010")&"<br>" %> </body> </html>
Create a asp file and save to path root-path/myasp/
Run
http://localhost/myasp/asp_cdate.asp
Screenshot