Sep 03, 2010, 4:54 PM
[CLOSED] Is there a way to give the DateField multiple sets of min/max dates?
Hi,
With a DateField, I can set a MinDate and MaxDate. With a NumberField, I can set a MinValue and Max Value. But from what I can see, there isn't a way to set a range of min/max values for these fields.
So, as an example, it would be useful to use a DatePicker to allow picking values from from between Jan 1 and Feb 28 OR Oct 1 and Nov 30. The calendar UI would then automatically enable/disable the correct range of dates. But I can't see a way to do this. Is it possible?
From what I can see, for a NumberField, I might be able to set a custom Validator function to be invoked, but the challenge with the DateField is how to limit input from the picker in the first place and get it to grey out/disable the correct ranges?
I've looked around a bit to see how other widget libraries deal with this, including even WinForms DateTimePicker etc, and they all seem to offer a single Min and Max approach, so I am assuming this is a very edge case scenario...
Thanks!
With a DateField, I can set a MinDate and MaxDate. With a NumberField, I can set a MinValue and Max Value. But from what I can see, there isn't a way to set a range of min/max values for these fields.
So, as an example, it would be useful to use a DatePicker to allow picking values from from between Jan 1 and Feb 28 OR Oct 1 and Nov 30. The calendar UI would then automatically enable/disable the correct range of dates. But I can't see a way to do this. Is it possible?
From what I can see, for a NumberField, I might be able to set a custom Validator function to be invoked, but the challenge with the DateField is how to limit input from the picker in the first place and get it to grey out/disable the correct ranges?
I've looked around a bit to see how other widget libraries deal with this, including even WinForms DateTimePicker etc, and they all seem to offer a single Min and Max approach, so I am assuming this is a very edge case scenario...
Thanks!
Last edited by Daniil; Sep 04, 2010 at 5:28 PM.
Reason: [CLOSED]