Re: [flexcoders] Need Help on Date Globalization in Flex 3
try this. make a calss with some static functions public class CommonFunctions { public function CommonFunctions():void {} import mx.formatters.DateFormatter; private static var dfconv:DateFormatter = new DateFormatter(); public static function formatDate(date:Date, format:String):String { dfconv.formatString=format; return dfconv.format(date); } } now you can pass in : *CommonFunctions.formatDate(theDate,, MMM. D, );* would output : Tuesday, Sept. 8, 2005 see here for more date formats http://livedocs.adobe.com/flex/201/html/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveDocs_Book_Partsfile=formatters_094_6.html On Sat, Mar 1, 2008 at 6:31 AM, [EMAIL PROTECTED] wrote: Hi There, Could any one please help me out in implementing globalization of date format in Flex 3, when I choose the language as US_English or Spanish or French for example I have to change the date format on the display to* dd/mm/* or*mm/dd/ *, etc based on the locale chosen. Which approach is better to implement this logic. Expecting to get your help soon. Cheers, Madhu K *Please do not print this email unless it is absolutely necessary. Spread environmental awareness.*
Re: [flexcoders] Need Help on Date Globalization in Flex 3
Hi Madhu, the best thing to do in my opinion is to put your date mask in your resource bundle and change it to whatever you'd like to use for each locale. I blog a bit about I18N in flex3 a little while back .. http://www.jmpj.net/jason/index.cfm/2007/12/19/I18n-in-Flex-3--pros-and-cons Hope this helps. -- Jason Sheedy www.bytespring.com www.jmpj.net - - On 02/03/2008, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Hi There, Could any one please help me out in implementing globalization of date format in Flex 3, when I choose the language as US_English or Spanish or French for example I have to change the date format on the display to* dd/mm/* or*mm/dd/ *, etc based on the locale chosen. Which approach is better to implement this logic. Expecting to get your help soon. Cheers, Madhu K *Please do not print this email unless it is absolutely necessary. Spread environmental awareness.*
Re: [flexcoders] Need Help on Date Globalization in Flex 3
[EMAIL PROTECTED] wrote: Could any one please help me out in implementing globalization of date format in Flex 3, when I choose the language as US_English or Spanish or French for example here's one approach (based on CLDR data, which is a darned good idea): http://as3localedata.riaforge.org/