ÄúµÄλÖãºÑ°ÃÎÍøÊ×Ò³£¾±à³ÌÀÖÔ°£¾VBScript£¾VBScript


objects constants operators statements functions properties methods






FUNCTION:  DateValue( )

DateValue(Date)

The DateValue function converts an argument into the variant of subtype Date.

The Date argument must be a string in valid date format or you will get an error message.

Code:
<% mystring = "06/26/1943" %>
<% =DateValue(mystring) %>

Output:
6/26/43

Code:
<% =DateValue("1/1/2001") %>

Output:
1/1/01