|This method is obsolete. See the Remarks section below.|
Utilities.StrToDate method converts the string specified by the
Str parameter to a Variant value that encodes date.
The method is applied to the following object:
The method has the following parameter:
Specifies the string to be converted to a value storing date. Str must consist of two or three numbers separated by the character defined by the
DateSeparator property. The order for month, day, and year is determined by the
ShortDateFormat property; possible combinations are: m/d/y, d/m/y, and y/m/d. If Str contains only two numbers, it is interpreted as a date (m/d or d/m) in the current year. If Str does not contain a valid date,
StrToDate raises an exception.
The integral part of the
StrToDate method's return value is the number of days that have passed since 12/30/1899. The fractional part of this value is zero.
This method is obsolete. It is supported for backward compatibility only. To convert a string to a date value, use the