DatePicker working incorrectly


#1

The issue I have is that the Date Picker shows a certain date and time. however, in the console log, the selected time tends to differ:

The following is what I get:

2014-09-06 15:23:24.814 HypnoNerd[23804:60b] Setting a reminder for: 2014-09-06 09:53:23 +0000

NOTE: It should be as follows:

Setting a reminder for: 2014-09-06 15:23:24.814


#2

I suspect the DatePicker is working fine.

The time shown in the log is in UTC time ("+0000"). Looks like you’re in UTC+6 (Bangladesh, Bhutan, Kazakhstan, and others; please forgive me if I’ve missed your country).

So the question is really how to log the time using your local time zone. Here are two possibilities; I’m sure there are others.

[ol]
[li] Look at NSDate’s -descriptionWithLocale: [/li]
[li] Look at NSDateFormatter[/li][/ol]