facebooksdk.net publish not working - can't get LoginButton.CurrentSession to publish to

后端 未结 1 619
小鲜肉
小鲜肉 2021-01-25 00:10

I\'ve got what seems to be a pretty simple problem - I\'m trying to use the facebooksdk.net to publish to a users feed.

First, I install with the following command, wh

1条回答
  •  無奈伤痛
    2021-01-25 00:26

    After some trial and error, I believe I've found the answer. The AccessToken is now accessible via Session.ActiveSession.CurrentAccessTokenData.AccessToken, which means the line of code should be:

    var token = Session.ActiveSession.CurrentAccessTokenData.AccessToken;
    var fbClient = new Facebook.FacebookClient(token);
    

    0 讨论(0)
提交回复
热议问题