Freigeben über


CREATEDATETIME Function (DateTime)

Creates a DateTime object from a date and a time.

DateTime := CREATEDATETIME(Date, Time)

Parameters

  • Date
    Type: Date The date that you want to use to create a DateTime. You cannot use an undefined date to create a DateTime.
  • Time
    Type: Time The time that you want to use to create a DateTime. You cannot use an undefined time to create a DateTime.

Property Value/Return Value

Type: DateTime

The concatenated DateTime.

Example

These examples of using the CREATEDATETIME function require that you create the following variables.

Name DataType

TestDate

Date

TestTime

Time

TestDateTime

DateTime

TestDate := TODAY;
TestTime := TIME;
TestDateTime := CREATEDATETIME(TestDate,TestTime);
…
TestDateTime := CREATEDATETIME(081111D,020000T);
…
TestDateTime := CREATEDATETIME(010101D,0T);

See Also

Concepts

DateTime Functions