XL2000: Format Function May Return an Incorrect Date (213514)
The information in this article applies to:
This article was previously published under Q213514 SYMPTOMS
In Microsoft Excel, if you run a Visual Basic for Applications macro
that uses the Format function with a date, you may notice the following
problems:
- When you use the General Date format or the Short Date format, the
month, day, and/or year of the dates may be switched.
For example, although the date January 10, 2000 may appear in the cell
as 1/10/00, the actual value of the date is October 1, 2000 (10/1/00).
- When you use the General Date format or the Short Date format, some of the dates appear as text, not as valid dates.
This problem may occur if the day or year of a date is greater than 12.
For example, the date July 30, 1999 may appear in the cell as the text
string "30/07/99" instead of the date 30/07/99.
- When you use the Long Date format, dates may appear in the Medium Date format instead.
For example, if the date should appear as "Tuesday, August 12, 1999", it
may appear as 12-Aug-99 instead.
CAUSE
These problems may occur if you are using regional settings that use a date
order of either day-month-year or year-month-day.
STATUSMicrosoft has confirmed that this is a problem in the Microsoft products that are listed at the beginning of this article.
Modification Type: | Minor | Last Reviewed: | 10/11/2006 |
---|
Keywords: | kbbug kbdtacode kbpending KB213514 |
---|
|