I am working on display a map with annotation on it. What I have so far is
Annotation.h
#import <MapKit/MKAnnotation.h>
#import <Foundation/Foundation.h>
@interface Annotation : NSObject <MKAnnotation>
@end
MapViewController.m
Annotation *pin = [[Annotation alloc] init];
[pin title] = storeName;
[pin subtitle] = storeAddress;
[pin coordinate] = region.center;
[mapView addAnnotation:pin];
However, I got an error like below:
expression is not assignable for title, subtitle and coordinate
Does anyone have any idea about this issue?