- checkrecheckAsked on April 24, 2015 at 11:29 AM
I have a form that needs to show a future date and time, based upon the selection made (Timeframe). I want this future date or time to be displayed automatically based on selection. Is there a custom script that can achieve this? Many thanks!
- CharlieAnswered on April 24, 2015 at 01:58 PM
You can use the conditional logic to display specific date time field depending on the selection.
1. First, set multiple date field, add custom date and custom time on them.
2. In the conditions wizard, choose the first option.
3. Based from the rule, if an option is selected, show a specific date. In my case, if "Future Date 1" is selected, it will display date field named "Date1".
You can check how the form works here: http://form.jotformpro.com/form/51135381306952
I hope this helps.
- checkrecheckAnswered on April 24, 2015 at 02:06 PM
thanks for your reply. I think you misunderstood my question. The date that should appear is based on a previous selection. So say a user selects 7 days, the date and time that should be displayed should be exactly 7 days after the date and time of now.
Similarly if 12 hours is selected, the date and time should be of exactly 12 hours after now. Would you please help me? Thanks!
- BenAnswered on April 24, 2015 at 04:10 PM
Unfortunately that would not be possible to do at this time in JotForm Builder. You could however grab a full source code of your jotform and then have a developer create this functionality for you and show you how to re-apply the code on it.
If you make any changes in the Form Builder however, you would need to re-embed the form to see them and to re-apply the same functionality to your form so that the days and time is correctly applied and shown in the other field.
What you could do within the Form Builder is to create a calculation that would show the dates (not the time as well) and then show a message "within 12 hours" if that is their selection.
For example please take a look here: http://form.jotformpro.com/form/51136095032951
Do let us know if that would work for you.
- checkrecheckAnswered on April 24, 2015 at 06:43 PM
Thanks for your reply! Your solution is actually quite close to what I would like. The dates are of course correct. I would like to know how come the same is not possible to do with the time?
Thanks once again!
- JotForm SupportJanAnswered on April 24, 2015 at 11:19 PM
Ben used conditions and calculation to create that form. Please check the screenshots below.
- checkrecheckAnswered on April 29, 2015 at 08:59 AM
I would like to know how I can do the same so that the TIME is also included. Thank you.
- JotForm SupportJanAnswered on April 29, 2015 at 10:28 AM
We don't have a method or a function for the "time", only for the "date" which is why it will not work with the calculation field.
Hope this answered your question. Thank you.