The DateChooser control displays the name of a month, the year, and a grid of the days of the month, with columns labeled for the day of the week. The user can select a date, a range of dates, or multiple dates. The control contains forward and back arrow buttons for changing the month and year. You can let users select multiple dates, disable the selection of certain dates, and limit the display to a range of dates.
MXML Syntax
The <mx:DateChooser> tag inherits all the properties of its parent classes, and the following properties:
<mx:DateChooser
dayNames="["S", "M", "T", "W", "T", "F", "S"]"
disabledDays="No default."
disabledRanges="No default."
displayedMonth="Current month."
displayedYear="Current year."
firstDayOfWeek="0"
headerColor="#0FFFFFF"
headerStyleDeclaration="No default."
monthNames="["January", "February", "March", "April", "May",
"June", "July", "August", "September", "October", "November",
"December"]"
rollOverColor="#0xE3FFD6"
selectableRange="No default."
selectedDate="No default."
selectionColor="#0xCDFFC1"
showToday="true|false"
todayColor=""
todayStyleDeclaration="No default."
weekdayStyleDeclaration="No default."
change="Event handler; no default."
scroll="Event handler; no default."
/>
See Also
mx.controls.SimpleButton
mx.controls.CalendarLayout
mx.styles.StyleManager
| Constructors | |
DateChooser
()
Constructor. |
|
| Methods |
| Methods inherited from class mx.core.UIComponent |
getFocus
setFocus
getFocusManager
|
| Properties | |
| className:String
Name of this class. |
static | version:String
ComponentVersion is for internal use only. |
| todayStyleDeclaration:String
Style sheet definition to configure the numeric date text of the control. |
| headerStyleDeclaration:String
Style sheet definition to configure the date in the header area of the control. |
| weekDayStyleDeclaration:String
Style sheet definition to configure the weekday names of the control. |
| showToday:Boolean
[Read-Write]
If true, specifies that today is highlighted in the DateChooser control. |
| firstDayOfWeek:Number
[Read-Write]
Day of the week (0-6, where 0 is the first element of the dayNames array) to display in the first column of the DateChooser control. |
| displayedMonth:Number
[Read-Write]
Used with the displayedYear property, the displayedMonth property specifies the month displayed in the DateChooser control. |
| displayedYear:Number
[Read-Write]
Used with the displayedMonth property, the displayedYear property determines which month is displayed in the DateChooser control. |
| dayNames:Array
[Read-Write]
Weekday names for DateChooser control. |
| disabledDays:Array
[Read-Write]
Days to disable in a week. |
| selectableRange:Object
[Read-Write]
Range of dates between which dates are selectable. |
| disabledRanges:Array
[Read-Write]
Disables single and multiple days. |
| selectedDate:Date
[Read-Write]
Date selected in the DateChooser control. |
| monthNames:Array
[Read-Write]
Names of the months displayed at the top of the DateChooser control. |
| Properties inherited from class mx.core.UIComponent |
version
enabled
tabIndex
|
| Effects |
| Effects inherited from class mx.core.UIComponent |
showEffect
hideEffect
focusInEffect
focusOutEffect
|
| Effects inherited from class mx.core.UIObject |
creationCompleteEffect
moveEffect
resizeEffect
mouseDownEffect
mouseOverEffect
mouseOutEffect
mouseUpEffect
|
| Events | |
scroll | Handler for scroll events, which are broadcast when the month changes due to user interaction. Target contains a reference to the component that triggered the event. Type contains the name of the event. |
change | Handler for change events, which are broadcast when a date is selected. Target contains a reference to the component that triggered the event. Type contains the name of the event. |
| Events inherited from class: mx.core.UIComponent |
focusIn
focusOut
keyDown
keyUp
show
hide
valid
invalid
valueCommitted
|
| Styles | |
headerColor |
Type: Number
Format: Color
CSS Inheritance: yes
Color of the band at the top of the DateChooser control. The default value is #0FFFFFF |
rollOverColor |
Type: Number
Format: Color
CSS Inheritance: yes
Color of the background when the user rolls over the link. The default value is #0xE3FFD6. |
selectionColor |
Type: Number
Format: Color
CSS Inheritance: yes
Color of the background when the user selects the link. The default value is #0xCDFFC1. |
todayColor |
Type: Number
Format: Color
CSS Inheritance: yes
Color of today`s date. The default value is #2B333C. |
| Styles inherited from class mx.core.UIObject |
color
fontFamily
fontSize
fontStyle
fontWeight
textAlign
textDecoration
textIndent
marginLeft
marginRight
horizontalGap
verticalGap
|
| Constructor Detail |
DateChooser()
| Property Detail |
className:String
dayNames:Array
[Read-Write]
disabledDays:Array
[Read-Write]
disabledRanges:Array
[Read-Write]
displayedMonth:Number
[Read-Write]
displayedYear:Number
[Read-Write]
firstDayOfWeek:Number
[Read-Write]
headerStyleDeclaration:String
monthNames:Array
[Read-Write]
selectableRange:Object
[Read-Write]
selectedDate:Date
[Read-Write]
showToday:Boolean
[Read-Write]
todayStyleDeclaration:String
static version:String
weekDayStyleDeclaration:String