I am downloading some JSON data from a webservice. In this JSON I’ve got some Date/Time values. Everything in UTC.
How can I parse this date string so the result Date object is in the current locale?
For example: the Server returned “2011-05-18 16:35:01” and my device should now display “2011-05-18 18:35:01” (GMT +2)
My current code:
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
Date myDate = simpleDateFormat.parse(rawQuestion.getString("AskDateTime"));
It has a set timezone method:
all done!