5

我只是有时会收到此错误 - 似乎它有时只会发生。如果我刷新页面,它似乎会自行修复。有任何想法吗?

The request was aborted: Could not create SSL/TLS secure channel. 
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 

Exception Details: System.Net.WebException: The request was aborted: Could not create SSL/TLS secure channel.

从这段代码:

    string ThirdURL = "https://api.facebook.com/method/users.getInfo?uids=" + FacebookUserID + "&client_id=" + AppCode.Facebook.APPLICATION_ID + "&access_token=" + AccessToken + "&fields=first_name,last_name,current_location,email,birthday,sex,pic_square,locale&format=json";
    HttpWebRequest APIThirdRequest = (HttpWebRequest)WebRequest.Create(ThirdURL);
    StreamReader APIThirdResponse = new StreamReader(APIThirdRequest.GetResponse().GetResponseStream());

//error on line below -->
        string MoreAPIData = APIThirdResponse.ReadToEnd();
4

1 回答 1

1

这是 Facebook 方面的临时问题。虽然它持续存在,但解决方案是执行一个“try-catch 循环”,请求的最大重试次数为 x 次,即使它可能被认为是不好的做法。

自 2012-07-17 以来,问题本身已得到解决。

Facebook Developers 上关于该问题的门票:

于 2012-07-22T08:08:37.003 回答