User Guide

424 DateChooser component (Flash Professional only)
DateChooser.disabledRanges
Availability
Flash Player 6 (6.0.79.0).
Edition
Flash MX Professional 2004.
Usage
dateChooserInstance.disabledRanges
Description
Property; disables a single day or a range of days. This property is an array of objects. Each
object in the array must be either a Date object that specifies a single day to disable, or an
object that contains either or both of the properties
rangeStart and rangeEnd, each of
whose value must be a Date object. The
rangeStart and rangeEnd properties describe the
boundaries of the date range. If either property is omitted, the range is unbounded in that
direction.
The default value of
disabledRanges is undefined.
Specify a full date when you define dates for the
disabledRanges property. For example,
specify
new Date(2003,6,24) rather than new Date(). If you dont specify a full date, the
Date object returns the current date and time. If you dont specify a time, the time is returned
as
00:00:00.
Example
The following example defines an array with rangeStart and rangeEnd Date objects that
disable the dates between May 7 and June 7:
my_dc.disabledRanges = [{rangeStart: new Date(2003, 4, 7), rangeEnd: new
Date(2003, 5, 7)}];
The following example disables all dates after November 7:
my_dc.disabledRanges = [ {rangeStart: new Date(2003, 10, 7)} ];
The following example disables all dates before October 7:
my_dc.disabledRanges = [ {rangeEnd: new Date(2002, 9, 7)} ];
The following example disables only December 7:
my_dc.disabledRanges = [ new Date(2003, 11, 7) ];
The following example disables April 7 and April 21:
my_dc.disabledRanges = [ new Date(2003, 3, 7), new Date(2003, 3, 21) ];