How do I get to know when the cancel button is clicked from a Facebook appliaction in iPhone while authentication.
We can get the callback for other through delegate functions, but I don't know how to get the callback for the cancel button.
Facebook provides a delegate method which you can use:
- (void)fbDidNotLogin:(BOOL)cancelled;
You have to implement FBSessionDelegate and this method will be called if the person clicks on the cancel button.
Related
I am using SKStoreReviewController to get rating of app from the user so I need SKStoreReviewController delegate methods to track the user activity means what the user press from the popup "cancel" or "Submit".
SKStoreReviewController does not have a delegate. See https://developer.apple.com/documentation/storekit/skstorereviewcontroller
How is it possible to test / get notification about Facebook iOS app is just left?
Implemented Facebook Login button, and when coming back from FB login screen, need to do some extra steps in my app. But viewDidAppear is not get called in that view controller.
Do you have any idea? Need to use AppDelegate methods?
You can add an observer for UIApplicationWillEnterForeground notification.
And you could add some logic right before calling the facebook button, to check if the app has entered background because of that or simply because the user has pressed home button.
I am able to read and write data from my iOS app(Central). Just after Delegate connectPeripheral:periphal is called, OS gives an alert asking for authentication PIN with two buttons "Cancel" and "Pair".
I am not able to get any notification when user presses "Cancel" or "Pair" button. I am also not able to detect if the pairing is successful or not.
self.peripheral.state always returns 2 (connected)
I have done some research to handling Cancel event of pairing popup but unfortunately apple doesn't provide any delegate to handle it.
I'm working on an app that uses Parse backend, and I've implemented Facebook login following Parse's tutorial. I am not using PFLoginViewController provided by Parse, only the login method calls to the PFFacebookUtils class. The implementation works well.
What I now need is the 'login with Facebook' button. Since I'm not using LoginViewController, I can't use the loginView property that would give me the button. Nor can I use the FBLoginView from Facebook SDK as the view neither surfaces the button nor allows one to override the method that is called when the button is clicked.
What is the best way to extract the button from existing SDKs - either Parse or Facebook - so that the button is always visually up to date?
I m working on facebook login. Everything is fine, when I tap on the login button it will take me to safari (or FB app) and ask me for FB login.
my question is how to make safari return to my app if I decide not to login and hit cancel button? its currently taking me to my facebook main page after hitting cancel and is not useful
thanks in advance!
I don't know how to do it exactly as you suggest but what you could do is create another view controller with a web view inside of it, and a navigation bar at the top that has a cancel button on it. This way they could log on to facebook from within the app, so they don't have to switch between things which can be a little lengthy! It would also allow an easy cancel button with 'dismissModalViewController' or whatever it has changed to in iOS6. I believe this should work :)