- tammy1973Asked on January 12, 2016 at 05:35 AM
I would like to have a field which shows a date range/period of time to make it clearer to the customer which period they are looking at.
Customer enters the date of their closing balance in one field, e.g. 29.1.16
The second field is a calculation widget which calculates the start date of the period as the date of the closing balance minus 28 days, e.g. 1.1.16.
Ideally I would have a third field that I'd call 28 day period and which displays 11.1.16 - 29.1.16
This would then be followed by a forth number field with the question "what is the lowest amount in your account during this 28 day period?"
Is it possible to display the date range as described as third field above? Many thanks, Tamara
- grade4pagasaAnswered on January 12, 2016 at 07:43 AM
Randy here, a fellow JotForm user.
Does this sample form I made meet your specifications?
I didn't quite get your 4th specs about the lowest amount bit.
Hope this helps while waiting for the JotForm Support Team's reply.
- tammy1973Answered on January 12, 2016 at 07:48 AM
yes, that's great, exactly what I need, but what formula did you use to get the date range?
- grade4pagasaAnswered on January 12, 2016 at 08:57 AM
You can use the Form Calculation or a regular Textbox to get the desired result.
In this example, I used a textbox with the configurations detailed in figure 1.
If closingDate is Filled, then assign the text string value of closingDate to closing balance (txt) field.
This will make sure that the DDMMYYYY date format you specified will be followed.
figure 2 (how to change the values from number to text string)
You can also use the dateString function but this will not follow the DDMMYYYY date format you want.
- grade4pagasaAnswered on January 12, 2016 at 09:03 AM
For the date range itself, I just used a textbox again to join the text values of the startDate and closingBalance fields with a dash (-) in between then assigned the resulting value to the field named date range.
Apologies for creating a new post. I couldn't edit my reply above due to an unknown glitch.
- grade4pagasaAnswered on January 12, 2016 at 10:13 AM
Here's a form with lesser fields & conditions (but will yield the same result).
- JotForm SupportBJoannaAnswered on January 12, 2016 at 12:49 PM
Thank you, grade4pagasa for providing this solution.
Feel free to contact us if you have any other questions.
- tammy1973Answered on January 18, 2016 at 06:35 AM
Thank you so much, I have now managed to do it, much appreciated.
- CarinaAnswered on January 18, 2016 at 09:40 AM
Thank you for updating us.
If you need further assistance please let us know.
- AA_CAnswered on January 18, 2016 at 09:44 AM
@Randy, You need to get on the staff, good work my friend.
- grade4pagasaAnswered on January 18, 2016 at 10:04 AM
Thanks for the kind words, Robert !
I'm just a & frustrated-coder who tries to help fellow JotForm users anyway I can.