LOTUSSCRIPT LANGUAGE


CDat function
Example

Converts a numeric value or string value to a date/time value.

Syntax

CDat ( expr )

CVDate is acceptable in place of CDat.

Elements

expr

Return value

CDat returns a date/time value.

The data type of the return value is a Variant of DataType 7 (Date/Time).

If the integer part of expr is not in the range -657434 to 2958465, the function raises an error.

CDat(0) returns the date/time value December 30, 1899, 12:00:00 AM, formatted as 12:00:00 AM. CDat(EMPTY) returns the same value.

Usage

CDat converts expr to a date/time value in the LotusScript date/time format.

CDat uses different conversion rules depending on the form of expr:


If LotusScript cannot convert the value to a date/time, the function raises an error.

Language cross-reference

@Time function in formula language

@TextToTime function in formula language

Example
See Also