Cicode Programming Reference > Cicode Function Categories > Time and Date Functions Introduction > TimeToOLEDate

TimeToOLEDate

Converts a CitectSCADA time/date value to an OLE DATE value (this should be stored in a REAL).

Syntax

TimeToOLEDate(Time, Local)

Time:

Time/date variable.

Local:

0 - The return value is output as UTC time.

1 - The return value is output as Local time.

Return Value

Returns an OLE date value.

Related Functions

TimeCurrent, OLEDateToTime

Example

Real = TimeToOLEDate(TimeCurrent(), 1);
! Sets Real to the local date/time value

See Also

Time/Date Functions