开发者

Why am i not able to make facebook c# sdk 4.1 sample work?

开发者 https://www.devze.com 2023-02-05 22:12 出处:网络
I have setup my application on facebook and changed the appid and secretkey in the sample. When i click login to facebook a popup does come but when i enter my username and password for facebook it ke

I have setup my application on facebook and changed the appid and secretkey in the sample. When i click login to facebook a popup does come but when i enter my username and password for facebook it keeps failing. To be specific this function is fails :-

[ScriptableMember]
        public void LoggedIn(string uri) //string sessionKey, string sessionSecret, int expires, string userId, string allowedPermissions)
        {
            FacebookAuthenticationResult authResult;
            if (FacebookAuthenticationResult.TryParse(uri, out authResult))
            {
                fbApp.Session = authResult.ToSession();
                loginSucceeded();
            }
           开发者_JAVA技巧 else
            {
                failedLogin();
            }
        }

and to be specific this line fails

 if (FacebookAuthenticationResult.TryParse(uri, out authResult))

I do get the uri which is

http://localhost:18201/LoginSuccessful.htm#access_token=somaccesstoeknrandomstring&expires_in=5894

Can anybody tell me what am i doing wrong?

0

精彩评论

暂无评论...
验证码 换一张
取 消