0

In Flex i have two date fields startdate and enddate.. now, if i select a start date the date range for the end date should show only the next two days..(i.e: End date = start date + 2 days and other days should be disabled and cant be selected).

 private function onScroll():void {
            endDate.selectableRange("");}
<mx:DateField id="startDt" change="onScroll()"/>
<mx:DateField id="endDate"/>

Need suggestion.

4

1 に答える 1

3

これをチェックしてください...これはあなたを助けるかもしれません

<mx:DateField id="stDate"/>
<mx:DateField id="endDate" selectableRange="{{rangeStart: stDate.selectedDate,rangeEnd:new Date(stDate.selectedDate.fullYear,stDate.selectedDate.month,stDate.selectedDate.date+2)}}"/>
于 2012-04-19T13:23:04.677 に答える