You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am following Your Instructions. It was working in my sample project. When i try to implement in my original project i get error.
private void LoginSucceded(string accessToken)
{
var fb = new FacebookClient(accessToken);
fb.GetCompleted += (o, e) =>
{
if (e.Error != null)
{
Deployment.Current.Dispatcher.BeginInvoke(() =>
{
MessageBox.Show(e.Error.Message);
return;
});
}
var result = (IDictionary<string, object>)e.GetResultData();
var id = (string)result["id"];
var url = string.Format("/Views/FacebookInfoPage.xaml?access_token={0}&id={1}", accessToken, id);
var rootFrame = (App.Current as App).RootFrame;
Deployment.Current.Dispatcher.BeginInvoke(() =>
{
rootFrame.Navigate(new Uri(url, UriKind.Relative));
});
};
fb.GetAsync("me?fields=id");
}
In this method i am getting error in this line: fb.GetAsync("me?fields=id");
error..System.NotImplementedException: This property is not implemented by this class.
at System.Net.HttpWebRequest.SetUserAgent(String value)
at System.Net.HttpWebRequest.set_UserAgent(String value)
at Facebook.HttpWebRequestWrapper.set_UserAgent(String value)
at Facebook.HttpWebRequestWrapper.TrySetUserAgent(String userAgent)
at Facebook.FacebookClient.PrepareRequest(HttpMethod httpMethod, String path, Object parameters,
Type resultType, Stream& input, Boolean& containsEtag, IList`1& batchEtags)
at Facebook.FacebookClient.ApiAsync(HttpMethod httpMethod, String path, Object parameters, Type resultType, Object userState)
at Facebook.FacebookClient.GetAsync(String path, Object parameters, Object userState)
at Facebook.FacebookClient.GetAsync(String path)
at TestReactive.com.beno.WP7Client.ViewModels.FacebookViewModel.LoginSucceded(String accessToken)
at TestReactive.com.beno.WP7Client.ViewModels.FacebookViewModel.webBrowser_Navigated(Object sender, NavigationEvPID:0ED1004E TID:0F8A0042 entArgs e)
at Microsoft.Phone.Controls.WebBrowser.FireNavigatedEvent(Uri uri)
at Microsoft.Phone.Controls.WebBrowserInterop.ReversePInvokeThunk.OnNavigated(Int32 webBrowserControlId, String uri)
Please help me to resolve this problem.
The text was updated successfully, but these errors were encountered:
I am following Your Instructions. It was working in my sample project. When i try to implement in my original project i get error.
private void LoginSucceded(string accessToken)
{
var fb = new FacebookClient(accessToken);
In this method i am getting error in this line:
fb.GetAsync("me?fields=id");
error..System.NotImplementedException: This property is not implemented by this class.
at System.Net.HttpWebRequest.SetUserAgent(String value)
at System.Net.HttpWebRequest.set_UserAgent(String value)
at Facebook.HttpWebRequestWrapper.set_UserAgent(String value)
at Facebook.HttpWebRequestWrapper.TrySetUserAgent(String userAgent)
at Facebook.FacebookClient.PrepareRequest(HttpMethod httpMethod, String path, Object parameters,
Type resultType, Stream& input, Boolean& containsEtag, IList`1& batchEtags)
at Facebook.FacebookClient.ApiAsync(HttpMethod httpMethod, String path, Object parameters, Type resultType, Object userState)
at Facebook.FacebookClient.GetAsync(String path, Object parameters, Object userState)
at Facebook.FacebookClient.GetAsync(String path)
at TestReactive.com.beno.WP7Client.ViewModels.FacebookViewModel.LoginSucceded(String accessToken)
at TestReactive.com.beno.WP7Client.ViewModels.FacebookViewModel.webBrowser_Navigated(Object sender, NavigationEvPID:0ED1004E TID:0F8A0042 entArgs e)
at Microsoft.Phone.Controls.WebBrowser.FireNavigatedEvent(Uri uri)
at Microsoft.Phone.Controls.WebBrowserInterop.ReversePInvokeThunk.OnNavigated(Int32 webBrowserControlId, String uri)
Please help me to resolve this problem.
The text was updated successfully, but these errors were encountered: