Android facebook integration




Getting Android app integrated with facebook application is pretty straight forward. If you follow the guide here, it will guide to from start until end.

https://developers.facebook.com/docs/facebook-login/android/


The only point that i would like to emphasis here is, this line of code in "onActivityResult". You will get resultCode = -1 even though you have signed in successfully. That is why, forwarding result to callbackManager is important as it will be able to tell for sure if your user did signed in, signed out or cancel.

protected void onActivityResult(int requestCode, int resultCode, Intent data) {
    super.onActivityResult(requestCode, resultCode, data);
    callbackManager.onActivityResult(requestCode, resultCode, data);
}



Comments

Popular posts from this blog

The specified initialization vector (IV) does not match the block size for this algorithm