I cannot seem to get the proper year out of a DateFormatter. Can someone tell me what I am doing wrong:
I have a component: <mx:Canvas xmlns:mx="http://www.adobe.com/2006/mxml" width="100%" height="100%" creationComplete="init()"> <mx:Script> <![CDATA[ import mx.collections.ArrayCollection; [Bindable] private var date:Date = new Date(); [Bindable] private var ac:ArrayCollection = new ArrayCollection(); private function init():void{ var obj:Object = new Object; obj.date = date; obj.datetime = date; ac.addItem(obj); } ]]> </mx:Script> <mx:DateFormatter id="fmtDate" formatString="MM-DD-YYYY"/> <mx:AdvancedDataGrid dataProvider="{ac}" height="100%" width="100%"> <mx:columns> <mx:AdvancedDataGridColumn dataField="date" formatter="{fmtDate}"/> <mx:AdvancedDataGridColumn dataField="datetime"/> </mx:columns> </mx:AdvancedDataGrid> </mx:Canvas> The Date column resolves to "07-16-400". The Datetime column to "Wed Jul 16 19:08:39 GMT-0400 2008". Why does my year show up as 400???