Skip to main content

Date Time

Picker group: Basic Elements · Project type: dateTime · Reference version: 27.0.29

Use Date Time (dateTime) for an analog clock, digital clock, or combined date and time display. Add Date Time and choose analog, digital, or datetime.

For analog clocks, configure hour/minute marks and hand colors. For digital and combined displays, choose whether to show seconds, date, time, and AM/PM, then set date position, typography, and spacing. Set a locale and, when needed, an IANA time zone such as America/New_York.

Check that the date and time fit without clipping and that the target device reports the intended time. This is a display component, not a scheduling engine.

Configure in the VS Code sidebar​

Select the Date Time on the visual canvas, then open Element Properties. The screenshot shows the selected control in the development environment; click it to open the full-resolution image. Expand the groups below; scroll the sidebar to reach settings below the visible area.

Date Time selected in VS Code with its Element Properties sidebar and visual canvas

Sidebar controlWhat it does
VariantChoose Analog, Digital, or Date & Time. This choice changes the relevant clock appearance settings.
Content → Label Text / Label Position / Label GapAdd a caption and position it above or below the clock, with the desired separation.
Content → LocaleChoose formatting conventions for the displayed date and time.
Content → Time ZoneChoose the clock timezone; the example uses America/New_York.
AppearanceConfigure the selected clock presentation, including the supported marks, hands, colors, and typography.

The shared Element name, datasource, sizing, CSS, and mode controls are explained in the sidebar reference. Settings depend on the selected type and variant.

Settings explained​

Select the control and open Element Properties. Expand the relevant sections for its variant, appearance, content, and actions. The property keys below identify the saved project settings; the visible groups vary by control and variant.

SettingProject propertyWhat to configure
VariantvariantAnalog clock, digital time, or combined datetime display.
Time formatuseAmPm, showSecondsChoose 12-hour AM/PM presentation and whether seconds are visible.
Combined displayshowDate, showTime, datePositionControl visible sections and their relative positions in the combined display.
LocalelocaleA BCP 47 locale such as en-US controls localized formatting.
Time zonetimeZoneUse an IANA name such as America/New_York; leave unset for the runtime default.
Analog marksminuteMarkColor, hourMarkColorStyle minute and hour marks separately.
Analog handshourHandColor, minuteHandColor, secondHandColorGive each hand a readable color.
Date stylingdateColor, dateFontSize, gapStyle the date and its spacing from other label sections.

Worked setup​

  1. Insert Date Time and name it RoomClock.
  2. Choose DateTime to display date and time together, or Analog/Digital for the other presentations.
  3. Set locale to en-US and time zone to America/New_York for the example.
  4. Enable AM/PM, choose whether seconds are useful, and place the date below the time.
  5. Size the element for the longest expected date and preview it.

The screenshot records the runtime clock at capture time. The control reads time from the runtime; it does not set the panel clock, schedule equipment, or provide a date-entry field.

Verify the result​

Check time-zone selection, localization, 12/24-hour readability, and the target device clock. Long month names and large typography must fit the available space.

Save the project, run Run Project Health Check, and test in Open Live Preview (Browser). Hardware-backed behavior also needs verification in the target runtime with the actual integration available.

Dynamic text in 27.0.5​

Text labels now resolve dynamic tokens and HTML instead of showing raw token strings. Use the correct global variable, page parameter, or datasource scope, then check the rendered label in Live Preview.