2 Replies Latest reply on Aug 20, 2010 2:03 PM by injpix

    JSON response and datetime formats--is there one that Flex likes?

    JoshBeall Level 1

      Hi All,

       

      I've got a .NET service that returns JSON.  By default, .NET will return strings that look like "\/Date(47825093485)\/" for any date formats.  You can read about that here:

      http://weblogs.asp.net/bleroy/archive/2008/01/18/dates-and-json.aspx

       

      I couldn't figure out how to get Flex to do anything meaningful with that, so I changed my service to return the datetime as a string.  I can format it however I want.  I tried this format: "08/20/2010 16:32:47".  But, again, Flex doesn't parse that, it just returns it as a string.  Is there any format I can use to get Flex to automatically parse the value into a Date object?  Or do I need to return a string from my service, then manually parse it into a Date object on the Flex side?

       

      Thanks for any tips...

       

        -Josh