I want to add event to native calender.I am having problem in getting date accurate time from string. I have set locale,24 hr format. but still getting the same bug.
EKEvent *event = [EKEvent eventWithEventStore:self.eventStore];
NSDateFormatter *dateFormatter = [[NSDateFormatter alloc] init];
NSLocale *locale =[[[NSLocalealloc]initWithLocaleIdentifier:@"en_US_POSIX"]autorelease];
[dateFormatter setLocale:locale];
[dateFormatter setDateFormat:@"dd/MM/yyyy HH:mm"];
event.startDate=[dateFormatter dateFromString:@"10/02/2011 15:39"];
And event.startDate is getting set as : 2011-02-10 10:09:00 GMT
Can anyone help???
I think your event.startDate is re initializing,
Its showing the current time, i think so.
Check whether any code there like
EDIT:
how you checking your event.startDate vale? If it is by using NSLog check this answer.