English 中文(简体)
如何利用窗户电话建立围墙 7 本地人
原标题:How to make a wall post using windows phone 7 native app

我在Windows 7. 电话线上建立了本地用户。

用户在登记新用户时将向我们提供标识证书。 我想要做的是,在我的肩上,让大家分享面对面的东西。

On clicking on the handle the selected image should be posted on to the user s wall and just display a message to the user that the image is posted successfully or not.

问题是,没有为Windows 7本地人提供开发型环境。

我希望能为此找到一些替代解决办法。

最佳回答

感谢这一联系。 我早些时候已经访问了这一联系。 我已把面孔融为7。 它的工作是适当的,能够建造围墙。

我的法典就是这样,

/Users Point on Share on facebook button

private void btnFacebookPost_Click(object sender, RoutedEventArgs e) {

       //Check if access tokens are already set.
        if (App.accessTokens == null)
        {
            GetAccessTokens();
        }
        else
        {
            //Use the access tokens to post on facebook
        }

    }

private void GetAccessTokens() {

       // Navigate user to facebooks login page
       // if user has already authenticated your app you ll receive the access tokens directly


        webBrowser.Source = new Uri("https://www.facebook.com/dialog/oauth?client_id= your app id &redirect_uri=https://www.facebook.com/connect/login_success.html&response_type=token&scope= whatever extended permissions you require ");

    }

//On The Navigated event of web browser check for access tokens //Use the facebook c# sdk to get the access tokens from the url

void webBrowser_Navigated(object sender, System.Windows.Navigation.NavigationEventArgs e) {

        FacebookClient fbClient = new FacebookClient();

            FacebookOAuthResult oauthResult;
            if (fbClient.TryParseOAuthCallbackUrl(e.Uri, out oauthResult))
            {
                // The url is the result of OAuth 2.0 authentication
                if (oauthResult.IsSuccess)
                {

                    App.accessTokens = oauthResult.AccessToken;

                }
                else
                {

                    var errorDescription = oauthResult.ErrorDescription;
                    var errorReason = oauthResult.ErrorReason;
                }
            }
            else
            {
                // The url is NOT the result of OAuth 2.0 authentication.
            }

      }

现在,用C#.net的面板打成像,使墙站或按要求进行其他交易。

The problem with this method is that the application user and the facebook s logged in user may be different thus making a transaction to different account. Since the SSO for WP7 is not available this method should do the trick.

问题回答

暂无回答




相关问题
Facebook Connect login dialog not working

I am using Facebook Connect for iPhone and following the official instructions. I use the following code to display the login dialog: FBLoginDialog* dialog = [[[FBLoginDialog alloc] initWithSession:...

Facebook App Profile Tab is Empty ... No Content Displayed?

I can view my application via the http://apps.facebook.com/myapplication/ link and the content shows up correctly. I also added the application as a tab to a facebook page. However, when viewing the ...

Facebook Platform error: "Object cannot be liked"

I m working on a Facebook Application that generates wall posts. In testing these posts, I ve discovered that the Facebook Platform action of "liking" a post is failing. The specific error message ...

how to call showPermissionsDialog() in php (facebook api)?

I was reading over the documentation yet I could not figure out how to call Facebook.showPermissionsDialog() in php include_once ./facebook-platform/php/facebook.php ; $facebook = new Facebook(my ...

Facebook connect

If I plug in the facebook connect into my website, How can I prevent double signups? Lets say I have a user that s already signed up to my site but he clicked the connect with facebook, is there a ...

热门标签