hi . i implement Facbook connect for my app on the AnotherViewController
[based on NavigationController Project] , on there i have something to share to facebook . so when put this code on the viewDidLoad
. when user go to AnotherViewController with Push animation .
my FBSession appear to login !! i want when user select the button and actionSheet appear then decide to login to facebook
- (void)actionSheet:(UIActionSheet *)menu didDismissWithButtonIndex:(NSInteger)buttonIndex {
switch (buttonIndex) {
case 0:
session = [FBSession sessionForApplication:@"587421274743043f3177a2f86684e533" secret:@"d22ad909a2e670269edd4d4e79c61c2a" delegate:self];
[session resume];
if( session.isConnected )
{
[self showFBFeed];
}
else
{
FBLoginDialog* login = [[FBLoginDialog alloc] initWithSession:session];
[login show];
[login release];
}
break;
case 1:
[session logout];
break;
}
So when put that code on the viewDidUnload
method everything works fine but my facebook API Key and secret doesn't work !!! why ?
How could solve my prablem ? :|
Thank you .