android-simple-facebook
android-simple-facebook copied to clipboard
How to get information of the user ?
I'd like to get information of the user such as user name, email address, picture etc. What can I do?
I tested by using "get account" function in your demo. The size of List<Account> returned is zero. Here is my configuration:
// initialize facebook configuration
Permission[] permissions = new Permission[] {
Permission.PUBLIC_PROFILE,
Permission.PUBLISH_ACTION
};
SimpleFacebookConfiguration configuration = new SimpleFacebookConfiguration.Builder()
.setAppId(getResources().getString(R.string.app_id))
.setNamespace(getResources().getString(R.string.app_name))
.setPermissions(permissions)
.setDefaultAudience(SessionDefaultAudience.EVERYONE)
.setAskForAllPermissionsAtOnce(false)
.build();
SimpleFacebook.setConfiguration(configuration);
Did I do anything wrong or I have to use other method? Thanks
Any idea? Thanks
Hi hope it is not late nothing is wrong except the fact that you just setup the client you need now to write the piece of code that will give you the needed information
check out this https://github.com/sromku/android-simple-facebook/wiki/Get-profile
and don't forget to login in first