SKVectorMapView: unrecognized selector

I am implementing the Skobbler SDK (v2.5), but I have a problem with the steps of the first step.

Application error with this error: [SKVectorMapView displayTrafficWithMode:]: unrecognized selector sent to the instance

This is AppDelegate Code

SKMapsInitSettings* initSettings = [[SKMapsInitSettings alloc]init];
initSettings.mapDetailLevel = SKMapDetailLevelLight;

[[SKMapsService sharedInstance] initializeSKMapsWithAPIKey:API_KEY settings:initSettings];

And this is the code of the ViewController:

- (void)viewDidLoad {
     [super viewDidLoad];

     SKMapView *mapView = [[SKMapView alloc] initWithFrame:CGRectMake( 0.0f, 0.0f,  CGRectGetWidth(self.view.frame), CGRectGetHeight(self.view.frame) )];
     [self.view addSubview:mapView];
}

Could you tell me what is wrong?

+4
source share
1 answer

Make sure you add “-ObjC” to your “other linker flag”.

"Select the project and select the target. Select the" Build Settings "tab and in the" Other linker flags "option, enter" ObjC. "From developer.skobbler.com

+4
source

Source: https://habr.com/ru/post/1609483/


All Articles