Add Date Time Picker
Audience:
Low-code EngineersSkill Prerequisites:
Forms,Tokens
Adds a date picker, time picker, or date and time picker to a Dynamic Field Container when the form loads. It works like a Date Time Picker field placed in the form builder.
See Dynamic Fields for how dynamic fields work and how to set up the container.
Typical Use Cases
- Ask for a date for each item in a list, for example a delivery date for each order line
- Add a follow-up date or appointment time that only some users need
Don't use it to
- Use the older date picker. That's Add Date and Time (Deprecated), which this action replaces.
Related Actions
| Action Name | Description |
|---|---|
| Add Date and Time (Deprecated) | The older date picker. |
Input Parameter Reference
This action has the common parameters, except Secure Input, Readonly and the custom validators. It also has:
| Parameter | Description | Supports Tokens | Default | Required |
|---|---|---|---|---|
| IsEnabled | When unchecked, the field is disabled. Enable Conditionally overrides it. | No | Checked | No |
| Picker Type | Date and Time, Date or Time. In expression mode, use dateandtime, date or time. | Yes | Date and Time | No |
| Client Format | How the value is displayed, as a .NET date and time format, for example dd/MM/yyyy or HH:mm. | Yes | empty string | No |
| Allow Input | When checked, users can also type the value instead of picking it. | No | Unchecked | No |
| Disable Dates | Date pickers only. None, In The Past or In The Future, to block all past or all future dates. | Yes | None | No |
| First Day of the Week | Date pickers only. Sunday or Monday. | Yes | Sunday | No |
| Disable Weekends | Date pickers only. When checked, Saturdays and Sundays can't be picked. | No | Unchecked | No |
| Inline | When checked, the calendar is always shown instead of opening when the field is clicked. | No | Unchecked | No |
| Allow dates outside constraints range | Date pickers only. When checked, an initial value outside the minimum and maximum is still shown. | No | Checked | No |
| Timepicker 24 hour mode | Time pickers only. When checked, times use the 24-hour clock without AM/PM. | No | Unchecked | No |
| Minimum Date | Date pickers only. The earliest date allowed, as yyyy-MM-dd, for example [DateTime:Now|yyyy-MM-dd]. Hidden when Disable Dates is In The Past. | Yes | empty string | No |
| Maximum Date | Date pickers only. The latest date allowed, as yyyy-MM-dd. Hidden when Disable Dates is In The Future. | Yes | empty string | No |
| Minimum Time | Time pickers only. The earliest time allowed, as HH:mm. | Yes | empty string | No |
| Maximum Time | Time pickers only. The latest time allowed, as HH:mm. | Yes | empty string | No |
| Minute Increment | Time pickers only. The step for minutes, for example 15. | Yes | 5 | No |
| Flatpickr Options Override (javascript object) | Advanced. A JavaScript object with flatpickr options that override the settings above, for example {weekNumbers: true}. | Yes | empty string | No |
"Date pickers" means Date and Date and Time. "Time pickers" means Time and Date and Time.
Output Parameters Reference
| Parameter | Description |
|---|---|
| Field ID Token Name | Optional. Token that receives the cleaned field ID. If empty, the ID is saved in [<FieldId>:Name]. |
When the form is submitted, the value is available in [<FieldId>], with the same extra tokens as a Date Time Picker placed in the form builder, such as [<FieldId>:Iso], [<FieldId>:Date], [<FieldId>:Time], [<FieldId>:Year], [<FieldId>:Month], [<FieldId>:Day] and [<FieldId>:Formatted].
Examples
To understand how to use the below examples, please see Running Examples.
1. Add a required delivery date that can't be in the past
Add this action to the form's On PreInit or On Init actions. It adds a date picker to the ExtraFields container that blocks past dates and weekends.
{
"Title": "Add Date Time Picker",
"ActionType": "AddDateTimePicker",
"Description": "Add the delivery date",
"Condition": null,
"Parameters": {
"ContainerId": "ExtraFields",
"FieldId": "DeliveryDate",
"FieldName": "Delivery date",
"InitialValue": "",
"IsEnabled": true,
"PickerType": {
"Expression": "",
"Value": "date",
"IsExpression": false,
"Parameters": {}
},
"ClientFormat": "dd/MM/yyyy",
"AllowInput": false,
"DisableFutureOrPast": {
"Expression": "",
"Value": "past",
"IsExpression": false,
"Parameters": {}
},
"FirstDayOfWeek": {
"Expression": "",
"Value": "monday",
"IsExpression": false,
"Parameters": {}
},
"DisableWeekends": true,
"IsRequired": "true",
"FieldIdTokenName": ""
}
}
Revised 09/25/2026