Skip to main content

Selecting the date and time format and display mode

Suggest edit Updated on December 13, 2021
Applicable to Theme UI-Kit applications

You can specify which date and time element selectors are displayed on the form at run time. For example, you can display a calendar widget with a corresponding text input field or display drop-down fields for selecting the month, day, and year.

Before you begin: In the layout of the form that you are editing, complete the following task: Adding a Date time control to a layout
  1. Click the control, and then click the View properties icon.
  2. On the Presentation tab of the Properties panel, use the Specify size option to specify the width of the control:
    • To automatically adjust the control area width to the layout, click Auto.
    • To manually specify a fixed width for the control, click Custom. In the Width fields enter the size in pixels or as a percentage.
  3. Set the Date/Time option to one of the following settings:
    • To automatically choose the proper format based on the data requirements, select Auto.
    • To display selectors for both date and time, select Date Time.
    • To display only selectors date, select Date.
    • To display only selectors time, select Time.
  4. To specify how dates and times are displayed in your application, set a Display mode list.
    Your choice for the Date/Time option determines which settings are available for the display mode.
    • To display a text input field with a selectable calendar widget, select Text input +calendar.
    • To display a series of drop-down fields for selecting months, days, and years, select Dropdown lists.
    • To display text input fields, select Text input.Note: This setting is available only if you set the Date/Time option to Date.
  5. Optional: To refine the display of the date and time, select one or more of the following options. Your choice for the Display mode option determines which options are available.
    • To display the month's full name at run time, select Display month in long format.
    • To override locale settings for users with locale settings that display the year before the month, select Ignore month and year position from locale settings.
    • To enable the use of native rendering on mobile devices, select Use native control on mobile.

      At run time, the date and time pickers use the mobile browser's native calendar date and time pickers.

    • To display the date according to your settings in the Read-Only Format section, select Display value using read-only formatting.
    • To use A.M. as the default when users enter times, select Set AM as default.
  6. For the Allow text entry option, click Yes (default) to enable the user to enter a text value in the field or click No to prevent text entry.
  7. Click Submit.
  • Previous topic Specifying read-only and edit options for a Date time control
  • Next topic Selecting spinners or drop-down fields for navigation
Did you find this content helpful? YesNo

Have a question? Get answers now.

Visit the Support Center to ask questions, engage in discussions, share ideas, and help others.

We'd prefer it if you saw us at our best.

Pega.com is not optimized for Internet Explorer. For the optimal experience, please use:

Close Deprecation Notice
Contact us