General Discussion

 View Only
  • 1.  Date duration restriction setup in form design

    Posted 08-03-2023 23:58


    I am designing at tool request form. and I need to setup a duration restriction date selector.

    Example: our tool cannot stay more than 60 days at site, if user keys in delivery and return date duration is more than 60 days, then user must adjust the date in order to proceed the submission.

    Currently I am using a recommendation as below from Varun Raval's post in the community:

    1. Date 1 – Date/Time Selector
    2. Date 2 - Date/Time Selector
    3. Count seconds (can be hidden on device) – Duration Math
    4. Total days – Calculation

    Result is I am able to trigger a notification using below setup:

    exception triggered but my concern is the user still can click "ignore" to proceed with the date selected. Is there any setting that can prevent them to proceed with errors? Thanks 

    Chang Chai Ng
    Field Trainer

  • 2.  RE: Date duration restriction setup in form design

    Posted 08-04-2023 15:20

    Hi Chang,

    I'm really curious about this "Ignore" option that's coming up in your "Errors on page" message. I can't duplicate this on my own test version so I've reached out to some folks internally to see if they could explain what is happening here.

    Just curious, in this form that you have set up and included screenshots from, are there any other questions set up or just the four listed in your post? In my test version it's just the four you listed in your post and when I try and submit the form and the Total Days is greater than 60 days I'll get an error message saying that I can't submit the form until I correct the errors.  Here's a screenshot of what I see.

    I'm testing on my Macbook and on an iPad. Looking at your screenshot I'm thinking you're using either Android or Windows. Could you confirm what device you're doing your testing on?

    Thanks Chang, I'll get back to you as soon as I hear back from other folks here.


    Pat Cooney
    Community Engineer

  • 3.  RE: Date duration restriction setup in form design

    Posted 08-06-2023 22:14
    Edited by Chang Chai Ng 08-06-2023 22:19

    Hi Pat,

    Yes I am using windows. These are some other questions in my repeatable section as below

    I want to trigger an message using answer exception to user when the duration of the dates are >60 days. but due to the max range i set is 60. Any ideas we can turn around?

    Chang Chai Ng
    Field Trainer

  • 4.  RE: Date duration restriction setup in form design

    Posted 08-08-2023 10:06

    Hi folks,

    just wanted to reply to this.

    The ignore option is available for repeat rows. In Chang's screen capture from the android device I can see the 1 of 1 peaking out from the top left side of the device behind the error message. In Pat's screen capture I don't believe he's using a repeat here. Pat can you confirm? When using the same form on a repeat you should also get the same ignore option in the error for iOS and Windows devices. So this is consistent behaviour.

    The ignore option is essentially a convenience specifically for repeats, as some users depending on the form's workflow, may need to avoid getting stuck on a repeat as opposed to moving forward to create another repeat. So essentially they know there is an error, but may not be able to fix it until later in the form. It all depends on their use case and workflow. Regardless the user would not be able to submit the form until the errors are corrected. They may be able to transfer the form if using teamwork, but would not be able to submit it.

    For Chang's example though I believe he would not want the ignore option to be there at all. Is this correct? This would prevent users from moving forward, and perhaps creating further repeats with the same error.  As mentioned above in some cases this wouldn't be desirable and may be necessary depending on the workflow. With that we've had some requests from customers to be able to shut off the pop-up reminders completely until the very end of the form. In their workflows they know the errors are there, they expect to see them and in turn get frustrated by the nagging pop-ups that they're not able to correct until much later. There has been a feature request for this already I'm fairly sure.

    From a User Experience point of view I can understand how different customers would want to be able to have it both ways. Because of that we'd need to introduce some configurability into the UI which would allow the admin to permit or prevent the ignore option. Or perhaps going a bit further, allow the field user to turn off error popups completely until the very end of the form. Again this all depends on the workflow and the experience of the field user and what the admin would like them to do.

    I'd be very interested in what other users think.

    We would need a Feature Request either way for this but please let me know your thoughts thanks!

    Craig MacMaster
    Senior User Experience Designer

  • 5.  RE: Date duration restriction setup in form design

    Posted 08-08-2023 16:36

    Thanks for this reply, @Craig MacMaster!

    @Chang Chai Ng, in addition to Craig's response above, I can add a couple more things that might help you out. 

    First up, I can confirm that even if your users select "Ignore" from the error notice when they are going through the repeatable sections, they will not be able to submit the form until these errors are cleared up. I can appreciate, from a User Experience point of view, that this could be confusing, thinking they've ignored the issue but still need to resolve it before they can submit the form, but at the very least, they will be unable to actually submit the form if they are exceeding the allowed date range.

    Second, in terms of the Answer Exceptions property and how to notify the user that they've exceeded the date range, the way you are using the Answer Exceptions property is not going to work for you (as I'm sure you've noticed). Since you have set your maximum value of the range at 60, you'll never be able to trigger the Exception, since that exceeds the maximum value of the range. The Answer Exception property isn't actually meant to be used like this, and you can find the full documentation for this property here:

    There are two options you can look at if you want to provide a more direct message to your users if they have exceeded the date range (more direct than just the default "number exceeds the maximum allowed" message that appears automatically under the Total Days At Site question that is).

    Option 1: Using a Recap Question

    The Recap question, if you aren't familiar with it, is used to make a count of all the exceptions of a certain type that has been triggered prior to the Recap question. If you choose this option you would remove the range properties in the Calculation question, and set the Answer Exception property to have a minimum of 60 and be Exclusive (so that it's triggered if the answer is greater than 60). You are now no longer using the data range in the Calculation question to determine if the form can be submitted or not, but rather using the number of exceptions getting counted by the Recap question. Once the form has less than 1 exception, it can be submitted. This also means the user will not be presented with the Error popup (with the "Ignore" option) if they put in a date ranger than exceeds 60 days.

    Here's what I did to set this up:

    1. Remove the allowable range from the Calculation question property
    2. Set the Answer Exceptions property for the Calculation question to trigger your "Rejected" type when the range is set with a minimum of 60 (if you are using Exclusive, meaning that once you exceed 60 the trigger will be affected).
    3. Create a new section (I've called mine "Summary") below your Repeatable section where your users are adding their dates.
    4. In this new section add a Recap question, configured as follows:
      • Set Question Text to a message that would make sense to your users
      • Set the Exception Category count property to "Rejected"
      • Set the Question Properties range to have a maximum of 0 (so that the form can't be submitted if any question has triggered the "Rejected" exception)
    5. Also in this section, add an Information Label question containing any information you'd like to present to your user if they have exceeded the date range on any of the tools
    6. Open the Conditional Logic tab and create a new rule to display the error message in the Information Label question you just created (and also to hide that question if there are no tools exceeding the 60 day maximum). To do this, my rule looks at the value of the Recap question and if it's greater than 0 it will display the Information Label question, with an else statement that hides the question.

    Now, when the user exceeds the date range, they will not be presented with an error message with an "ignore" option, but will get visual indicators that they have questions exceeding the range, as well as the message from your Information Label that displays. The user is also unable to submit the form until they have set all the date ranges to 60 days or less.

    The documentation on the Recap question is avialable here:

    Option 2: Using Conditional Logic

    This option is less involved, but outside of that Error popup, doesn't provide as much of a visual indication that there is an error. For this option you can use conditional logic to display an Information Label for each repeating section and you will not use the Answer Exception property on the Calculation question, just the range in the Question Properties, as you currently have it set up.

    If you go this route you will still get the Error message popup with the ignore button when the user sets the return date to be longer than 60 days, but there will be an additional message added to the form on that specific entry letting the user know they've exceeded the 60 day range. The user can still ignore the error message, but they won't be able to submit the form until they have corrected the date range.

    I hope Craig's response above, and my response here help you out, Chang, but please let us know if you have any further questions and how you plan to proceed. If you would like to log a Feature Request for the functionality Craig discussed in his response let me know and I'll make sure that your account team is made aware and a Feature Request is created for you.

    Pat Cooney
    Community Engineer

Reminder: Content posted to our Community is public content.  Please be careful not to post Intellectual Property that you do not have permission to share.  For more information please refer to our Terms Of Use