DateTimeElement
is used to represent a single input field that allows to select date and time.
Property | Type | Description |
---|---|---|
elementType | String | defaults to UIElementTypeConstants.dropdown |
elementId | String | unique ID for the interaction element |
label | String | accepts a string. It is the label of the dropdown. |
mode | DateTimePickerMode \n\n\n\n(.dateTime, .date, .time) | It is the mode of the date time picker. |
fromDateTime | Int | It is the start date of the date time picker. |
toDateTime | Int | It is the end date of the date time picker. |
dateTimeFormat | String | It is the format of the date time picker. |
timeZone | String | It is the time zone of the given date. |
defaultValue | Int | It is the default value of the input element. |
isOptional | Bool | It states if the input element is optional. |
DateTimeElement
class:
In this example, a new instance of DateTimeElement
is created with the elementId “1” and the label text “Select a Date”.
DateTimeElement
: