user1573310
user1573310

Reputation: 50

How to format date in flex?

I'm using Flex+java+Mysql.. in that i want to insert the datetime taking from flex to mysql in that i got date String like this

 Sat Aug 4 12:05:00 GMT+0530 2012

how to convert yyyy-MM-dd HH:mm:ss z this formate so please give code in java or flex...

Upvotes: 1

Views: 1065

Answers (2)

Java Developer
Java Developer

Reputation: 1901

In flex API Given DateFile class, in that we have two methods dateTOString(), stringTODate().

DateField.dateToString(dateInput.selectedDate,"DD-MM-YYYY");

Please Refere Below Doc. DateField

Upvotes: 1

Aravinth
Aravinth

Reputation: 363

DateField.dateToString(addr1.selectedDate,"YYYY-MM-DD").toString();

Upvotes: 1

Related Questions