Date and Time Fields

In the form designer, there is a single Date Time field that can be configured for both date and time values. In the classic form designer, the date and time fields are specialized field types that accept dates and times. Date time fields allow the user to select a date using a calendar picker or by typing in the input box. You can specify the date and time format and accepted range.

Settings

To edit a date time field

  1. Select the field on the canvas, and the options will appear in the right pane.
  2. Under Field label, enter the field label that will appear next to the field on the form.
  3. Under Variable, specify a name for the field variable associated with this field. If you do not specify a variable name, Forms will automatically assign the field one based on its label.
  4. Under Text above field and Text below field, you can enter any additional text that should appear with the field. Click the Insert variable button to include a variable with this text.
  5. Under Display options, select Required if users must fill in this field before submitting the form. Select Read-only if users should not be allowed to modify this field. For date fields, select Show time to allow users to specify a time along with the calendar date.
  6. Note: If a required field is hidden with a field rule, it is no longer required. A required field is only required when it appears on the form.

  7. Under Date format, specify how the date will appear using .NET formatting. This is the same formatting used to edit Laserfiche Workflow date tokens. Learn more.
  8. Under Time field select Show time to show the time fields. Selecting this option will expose the Time Format selections:
    • Select either AM/PM for 12-hour format, or 24 Hour for 24 hour format.
    • Select a format for how the time will appear using .NET formatting.
  9. Under Default date, or Default date and time when Show time is selected, enter the value that will appear in the field by default. If this option is blank, the field or fields will appear empty by default. Use the variable button to insert a date or time already associated with the process or form, or to insert the Date variable. Select Use current date, or Use current date and time when Show time is selected, to use the date and time when form was loaded.

    Note: If the field is set to read-only the Date variable will be replaced by the date the form is submitted. If the field is not read-only, the Date variable will be replaced by the date the form is first opened.

  10. To configure advanced options, click the Advanced tab.
    • Under Calculation, specify a formula that will populate the contents of this field. Learn more.
    • Under Minimum date, set the earliest date, and if Show time is checked the earliest time, that is allowed to be selected.
    • Under Maximum date, set the latest date, and if Show time is checked the latest time, that is allowed to be selected.
    • Under Tooltip, specify the help text that will appear when users hover over the field.
    • Under CSS classes, specify one or more CSS classes to assign this field. Learn more about using CSS.
  11. Your field changes will be applied to the form automatically.

To edit a date or time field

  1. Select the field on the canvas and click Edit.
  2. Under Field label, enter the field label that will appear next to the field on the form.
  3. Under Variable, specify a name for the field variable associated with this field. If you do not specify a variable name, Forms will automatically assign the field one based on its label.
  4. Under Field options, select Required if users must fill in this field before submitting the form. Select Read-only if users should not be allowed to modify this field. For date fields, select Show time to allow users to specify a time along with the calendar date.
  5. Note: If a required field is hidden with a field rule, it is no longer required. A required field is only required when it appears on the form.

  6. Under Text above field and Text below field, you can enter any additional text that should appear with the field. Click the Insert variable button to include a variable with this text.
  7. Under Date format, specify how the date will appear using .NET formatting. This is the same formatting used to edit Laserfiche Workflow date tokens. Learn more.
  8. Under Year range, specify the range of years that the field's value must fall within.
  9. Under Time format, specify how the time will appear.
  10. Time fields only: Under Time range, specify the hours that the field's value must fall within.
  11. Under Default value, enter the value that will appear in the field by default. If this option is blank, the field will appear empty by default. Use the variable button to insert a date already associated with the process or form, or to insert the Date variable.
  12. Note: If the field is set to read-only the Date variable will be replaced by the date the form is submitted. If the field is not read-only, the Date variable will be replaced by the date the form is first opened.

  13. To configure advanced options, click the Advanced tab.
    • Under Calculation, specify a formula that will populate the contents of this field. Learn more.
    • Under Tooltip, specify the help text that will appear when users hover over the field.
    • Under CSS class, specify a CSS class to assign this field. Learn more about using CSS.
  14. When you are finished editing the field settings, click Done. Your changes will be applied to the form automatically.