java - How to parse json object date to Android -


After parse json date for "itemprop =" text ">

like \ / date (1391802454790-0700) \ / How to (2014/01/31 11:44 AM) In Android

API results:. "," "Comment": "ogogog", "commentDate": "\ / date (13918024547900000) \ /", "commentReply": [], "NumberOfLikes": 1, " UniqueId ":" f786e0da-2e4a-430F-a37c-c60db1901e38 "," VIDEOID ": 65}

I tried the code below but this format (2014/01/31 11 : 44 o'clock).

  string json = "\ / not displayed as date (1391802454790-0700) \ /"; // string json = "comment; comment comment"; Json = json.replace ("/ dated (", "") .replace ("- 0700) /", ""); Long = tall. PartLong (JSN); Date d = new date (time); Println ("Dateeee ---->" + d);  

After

you should format d by using the date < Code> MM / Dd / yyyy hh: mm one

  string json = "/ date (1391802454790-0700) /"; Json = json.replace ("/ dated (", "") .replace ("- 0700) /", ""); Long = tall. PartLong (JSN); Date d = new date (time); Println ("Dateeee ---->" + d); System.out.println (new Simple Format ("MM / dd / yyyy hh: mm a") format (D));  

Excluded:

  data ----> Saturday Feb 08 01:17:34 IST 2014 02/08/2014 01:17 AM  

Comments

Popular posts from this blog

ios - How do I use CFArrayRef in Swift? -

eclipse plugin - Run java code error: Workspace is closed -

c - Error on building source code in VC 6 -