I just updated my app with the new Facebook 3.0 SDK for iOS. Before that, I used the SDK, which used FBSessionDelegate and FBRequestDelegate. In this SDK, we had to put this code in applicationDidFinishLaunching:
facebook = [[Facebook alloc] initWithAppId:FB_APP_ID andDelegate:self]; NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]; if ([defaults objectForKey:@"FBAccessTokenKey"] && [defaults objectForKey:@"FBExpirationDateKey"]) { facebook.accessToken = [defaults objectForKey:@"FBAccessTokenKey"]; facebook.expirationDate = [defaults objectForKey:@"FBExpirationDateKey"]; }
However, now with the new 3.0 SDK, they told me that all we need to do is import the framework and resource packs, and then “add the identifier with the name FacebookAppID to the * .plist package”. So, I did this, but when I call any code with FBSession in it, I get this error:
'FBSession: No AppID provided; either pass an AppID to init, or add a string valued key with the appropriate id named FacebookAppID to the bundle *.plist'
What can i do wrong?
Kwame source share