JotForm is a free online form builder which helps you create online forms without writing a single line of code. No sign-up required.
We believe that if one user has a question, there could be more users who may have the same question. This is why many of our support forum threads are public and available to be searched and viewed. If you’d like help immediately, feel free to search for a similar question, or submit your question or concern.
Is there a way to restrict times to a specific range?Asked by tlobaugh on September 02, 2014 at 06:00 PM
I want people to be able to enter the time an event occurred but I know that it must occur between 8 am and 4 pm. Is there a way to restrict time entries to that period? I am trying to avoid mistakes like 1 am when it should really say 1 pm.
We do have time field and also few widgets which should help you achieve your requirement. You can add a "Time" field which is under "Quick Tools" tab. Please check the screenshot below:
You may also like to take a look at the following time widgets as well:
Large Time Picker: http://widgets.jotform.com/widget/large_time_picker
ios7 Time : http://widgets.jotform.com/widget/ios7_time
Android Time: http://widgets.jotform.com/widget/android_time
I believe "ios7 Time" widget seems to suit your requirement better as it simply lists down the times with AM/PM.
Though it is not possible to restrict the time between 8 am and 4 pm but I believe you can just add a condition in your form to check the input and show an error message.
Hope this helps.
Do get back to us if you have any questions.
We have added a time field but I guess I'm not sure how to add a condition to the form as stated here. I can't see any condition type that would shoot back an error message. Can you give me a bit more guidance?
The following condition should work for you. I have tested this on a close time and it triggers the condition.
On this example, I simply set the submit button to show between the defined time. In other words, users will not be able to submit the form once it does not met the condition since the submit button will remain hidden when not between 8:00AM to 4:00PM. Take note that time in the condition is in 24HR Format. So you must use 8:00 to 16:00 (4:00PM). See the illustration guide above.
You can also add more actions like if you want not just by having the submit button hidden.
Go ahead and give it a try. If you need further assistance, let us know here.
This is a very old thread. I have moved your question to a new thread and you will be answered here: https://www.jotform.com/answers/927996