DATEVALUE function

Category: Date and time
Introduced: Excel 2003

Summary

Converts a date in the form of text to a serial number

Syntax

DATEVALUE(date_text) The DATEVALUE function syntax has the following arguments:
• Date_text Required. Text that represents a date in an Excel date format, or a reference to a cell that contains text that represents a date in an Excel date format. For example, "1/30/2008" or "30-Jan-2008" are text strings within quotation marks that represent dates. Using the default date system in Microsoft Excel for Windows, the date_text argument must represent a date between January 1, 1900 and December 31, 9999. The DATEVALUE function returns the #VALUE! error value if the value of the date_text argument falls outside of this range. If the year portion of the date_text argument is omitted, the DATEVALUE function uses the current year from your computer's built-in clock. Time information in the date_text argument is ignored.

Example

=DATEVALUE("8/22/2011")
=DATEVALUE("22-MAY-2011")
=DATEVALUE("2011/02/23")
=DATEVALUE("5-JUL")
=DATEVALUE(A2 & "/" & A3 & "/" & A4)

Microsoft Support Page

https://support.microsoft.com/en-us/office/datevalue-function-df8b07d4-7761-4a93-bc33-b7471bbff252

Back to Functions