Set Date Range in Date Field by Count?

  • Profile Image
    MerionVillageAssociation
    Asked on April 19, 2017 at 12:39 PM

    Are we able to configure a date field to accept dates only if they are so many days in the future of the current date? For example, is there an option that will allow us to prohibit a user from selecting a date that is less than 7 days in the future from the date when they are actually completing the form? This would be variable based on when the form is completed, so we wouldn't be able to specify a static range of dates and would need to use a "count" instead. 

  • Profile Image
    Nik_C
    Answered on April 19, 2017 at 02:04 PM

    Unfortunately, you can not disable the dates based on the user selection. What you could do with the Date field is to limit the range. So you can set the available days from today for next seven days for example:

    Is that close to what you're trying to achieve?

  • Profile Image
    MerionVillageAssociation
    Answered on April 19, 2017 at 09:44 PM

    Hi Nik! I'm not sure I phrased my question very well...

     

    We don't want the user's selection to impact the date range, rather we want to specify how many days from the current date can be selected into the future. 

     

    However, the forms where we would use this are live throughout the year, so we don't want to specify an exact date range. What we want to do is specify a range by number of days. 

     

    IE: If a user completes a form today (4/19/17) I want to be able to control at the form building level that the user completing the form can only pick a date that is 7 days or more in teh future from today / the date they are completing the form. 

     

    Using the example above, I would have to edit my form every single day to manually update the date range which would of course be very impractical. 

  • Profile Image
    Nik_C
    Answered on April 20, 2017 at 02:26 AM

    After further checking, I was able to find a way to achieve that. Here is how you can make only next 7 days available:

    1) Go to Date field properties:

    2) Disable the past:

    3) Enter the below in Custom Range:

    today+8>today+32000

    That means that dates between 8 days from now and 32000 days (which is enough) from now will be disabled.

    Hope it helps.

    Let us know how it worked.

    Thank you!

  • Profile Image
    MerionVillageAssociation
    Answered on April 20, 2017 at 01:34 PM

    This is incredibly helpful, thank you!!!