Come aggiungere la posizione non solo NSString ma con latitudine e longitudine, quindi mostra anche una mappa nel Calendario?Aggiungi posizione a EKEvent Calendario IOS
<EKCalendarItem>
@property(nonatomic, copy) NSString *location;
Codice:
EKEventStore *store = [[EKEventStore alloc] init];
[store requestAccessToEntityType:EKEntityTypeEvent completion:^(BOOL granted, NSError *error) {
if (!granted) { return; }
EKEvent *event = [EKEvent eventWithEventStore:store];
event.title = @"Event Title";
event.startDate = [NSDate date]; //today
event.endDate = [event.startDate dateByAddingTimeInterval:60*60]; //set 1 hour meeting
[email protected]"Note";
[email protected]"Eiffel Tower,Paris"; //how do i add Lat & long/CLLocation?
event.URL=[NSURL URLWithString:shareUrl];
[event setCalendar:[store defaultCalendarForNewEvents]];
NSError *err = nil;
[store saveEvent:event span:EKSpanThisEvent commit:YES error:&err];
NSString *savedEventId = event.eventIdentifier; //this is so you can access this event later
}];
Prova a fare quanto indicato nelle ans http://stackoverflow.com/questions/16647996/get-location- nome-da-latitudine-longitudine-in-ios – Revinder
Trovato una soluzione per questo ancora? Sono sulla stessa barca – jsetting32
@ jsetting32 Ancora nessuna soluzione, penso che non sia possibile forse: P – Metalhead1247