PDA

View Full Version : Date Field Format


MadamZuZu
07-30-2007, 04:08 PM
hi :)
i'm having a problem with the date picker.

mine looks like this:
<mx:DateField id="dtEnd" formatString="MM/DD/YYYY"/>

the probme is, is that when i try to pass it though a function, it comes back in this format:
Mon Jul 9 00:00:00 GMT-0400 2007
(using this: trace(dtStart.selectedDate);)
how do i make it come back as: 07/09/2007?

Thanks!

dr_zeus
07-30-2007, 04:44 PM
Use a DateFormatter (http://livedocs.adobe.com/flex/201/langref/mx/formatters/DateFormatter.html).