2

I recently upgraded the RevMob SDK of my cocos2d project, using Xcode 4.5. Below is a code to show what I have done:

#import <StoreKit/StoreKit.h>
#import <RevMobAds/RevMobAds.h>

- (void) applicationDidFinishLaunching:(UIApplication*)application{
    [RevMobAds startSessionWithAppID:@"my app id"];
    //some code here...
}

On running the project, on device or simulator, the app crashes with this error:

+[RevMobAds startSessionWithAppID:]: unrecognized selector sent to class

However, one thing which might be useful, is that when I added the RevMob framework to my Xcode, it gave me compilation errors (using LLVM GCC 4.2) for which I followed this answer.

Community
  • 1
  • 1
Sufian
  • 6,405
  • 16
  • 66
  • 120

1 Answers1

2

This method was included in version 5.0.0 (RevMob changelog), so make sure that the framework that you are using is at least 5.0.0.

Diogo T
  • 2,591
  • 1
  • 29
  • 39
  • The framework was included, however some other file (left behind by previous framework or something) was there which didn't have that function. It was somebody else's project so some files were wrongly copied, I guess. A very weird thing indeed, as Xcode didn't alert me on that. Thanks for the help though. :) – Sufian Dec 05 '12 at 07:18