In iOS6 for posting messages here i am using ACAccountType and SlRequest
but d=for this i need to retrieve the access token for some operations,
Following is the code which i am using to get data
ACAccountType *FBaccountType= [accountStore accountTypeWithAccountTypeIdentifier:ACAccountTypeIdentifierFacebook];
// Specify App ID and permissions
NSDictionary *dictFB = @{
ACFacebookAppIdKey:kAppId,
ACFacebookPermissionsKey: @[@"email",@"publish_stream", @"publish_actions"],
ACFacebookAudienceKey: ACFacebookAudienceFriends
};
[accountStore requestAccessToAccountsWithType:FBaccountType options:dictFB completion:
^(BOOL granted, NSError *e) {
if (granted) {
NSArray *accounts = [accountStore accountsWithAccountType:FBaccountType];
// it will always be the last object with single sign on
facebookAccount = [accounts lastObject];
NSLog(@"facebook account = %@",facebookAccount);
} else {
//Fail gracefully...
NSLog(@"error getting permission %@",e);
}
}];
but from the above code i am getting the following data s only 1]type 2]account description 3]username 4]objectid 5]properties 6]parent account
how can i get the access token using the above code in ios6
Here the issue has fixed by updated Facebook SDK 3.1.1 library