OpenersNotesSection(Spacer1)Details

OpenersPrimaryExamplesSection(Spacer1)Examples  (3)

OpenersExampleSection0(Spacer1)Basic Examples  (3)

Interpret dates with time:

Interpreter["DateTime"]["Friday, February 28, 2014, 10:30:00 AM GMT"]

Interpret dates with time in natural language:

Interpreter["DateTime"]["now"]

Restrict the value to be within a given range:

Interpreter[Restricted["DateTime", {Today,Today+Quantity[2,"Day"]}]]["tomorrow at 3 pm"]

Set a resolution of minutes:

Interpreter[Restricted["DateTime", {-Infinity,Now,"Minute"}]]["21:15 January 12th, 1990"]

Pure dates or pure times are not accepted:

Interpreter["DateTime"]["1989/12/03"]

Interpreter["DateTime"]["8 pm"]

({{DocumentationFooterIconsRelatedFunction.png, ({{See Also}, {(RefLink[Interpreter, paclet:ref/Interpreter])  ▪  (RefLink[SemanticImport, paclet:ref/SemanticImport])  ▪  (RefLink[Restricted, paclet:ref/Restricted])  ▪  (RefLink[Failure, paclet:ref/Failure])  ▪  (RefLink[DateObject, paclet:ref/DateObject])  ▪  (RefLink[TimeObject, paclet:ref/TimeObject])}, {Related Interpreter Types:  (RefLink[StructuredDateTime, paclet:ref/interpreter/StructuredDateTime])  ▪  (RefLink[ComputedDateTime, paclet:ref/interpreter/ComputedDateTime])  ▪  (RefLink[Time, paclet:ref/interpreter/Time])  ▪  (RefLink[Date, paclet:ref/interpreter/Date])  ▪  (RefLink[UnixTime, paclet:ref/interpreter/UnixTime])  ▪  (RefLink[ExcelDate, paclet:ref/interpreter/ExcelDate])  ▪  (RefLink[TimeZone, paclet:ref/interpreter/TimeZone])  ▪  (RefLink[DayOfWeek, paclet:ref/interpreter/DayOfWeek])  ▪  (RefLink[StructuredTime, paclet:ref/interpreter/StructuredTime])  ▪  (RefLink[ComputedTime, paclet:ref/interpreter/ComputedTime])  ▪  (RefLink[StructuredDate, paclet:ref/interpreter/StructuredDate])  ▪  (RefLink[ComputedDate, paclet:ref/interpreter/ComputedDate])  ▪  (RefLink[ComputedTimeZone, paclet:ref/interpreter/ComputedTimeZone])}})}})

({{DocumentationFooterIconsRelatedGuide.png, ({{Related Guides}, {▪(RefLinkPlain[Setting Up Input Interpreters, paclet:guide/InterpretingStrings])}})}})