Googlemaps Basic iOS Demo App Crash - Unrecognized Selector Sent to Instance

GoogleMaps basic iOS demo app crash - unrecognized selector sent to instance

I think you may have forgotten to make the class a GMSMapView delegate. The GMSMapViewDelegate bit after the () needs to be between <>

I don't assign that delegate as well as Googles Base Code does not assign it.
I have fortunetly managed to get it working. The google documentation on Google Maps states what follows:

Choose your project, rather than a specific target, and open the Build Settings tab.
In the Other Linker Flags section, add -ObjC. If these settings are not visible, change the filter in the Build Settings bar from Basic to All.

But their example project, after my examination, has the flag set on target. Setting it on the build target within my project in my case helped and my posted code works fine.

Error after submitting app to store -[GMSMapView animateToCameraPosition:]: unrecognized selector sent to instance

With the Google maps SDK, 'unrecognized selector' often occurs if you haven't included the -ObjC linker flag.

Could it be that you've included -ObjC in the debug build settings (which you might be using when running it from XCode), but it's missing in the release build settings (which it would use when you build to submit to the App Store)?

-[GMSMapView animateToCameraPosition:]: unrecognized selector sent to instance

Please mention which version of iOS you are using and did you setted delegate method for MAPview.

Please check the below link, may be helps you, all the best

GoogleMaps basic iOS demo app crash - unrecognized selector sent to instance

iOS GoogleMaps SDK error: [__NSCFDictionary objectForKeyedSubscript:]: Unrecognized selector sent

You may want to look into this question: objectForKeyedSubscript: crash on iOS 5.1

By the way, what's the version of Xcode you are using? What's the iOS SDK version you are using?


Developing an application with the Google Maps SDK for iOS requires the following:

  • Xcode 4.5 or later.
  • iOS SDK 6.0 or later.

Applications that use the Google Maps SDK for iOS will work on iOS 5.1 and above.

https://developers.google.com/maps/documentation/ios/intro

Unrecognized selector sent to instance inside UITableView

if you using like didSelectUserLabel

let userLabelRecognizer = UITapGestureRecognizer(target: self, action: "didSelectUserLabel")

you need to implement like

func didSelectUserLabel()
{

}

if you using like didSelectUserLabel:

let userLabelRecognizer = UITapGestureRecognizer(target: self, action: "didSelectUserLabel:")

you need to implement like

func didSelectUserLabel(recognizer: UITapGestureRecognizer) {
if recognizer.state == UIGestureRecognizerState.Ended {
let swipeLocation = recognizer.locationInView(self.tableView)
if let swipedIndexPath = tableView.indexPathForRowAtPoint(swipeLocation) {
if let swipedCell = self.tableView.cellForRowAtIndexPath(swipedIndexPath) {
// Swipe happened. Do stuff!
}
}
}
}
}


Related Topics



Leave a reply



Submit