我有问题。首先,这是我的代码:
HttpClient fond = new HttpClient();
using (var client = new HttpClient())
{
HttpClient.TransportSettings.Credentials = new System.Net.NetworkCredential("username", "pwd");
}
var reponse = await fond.GetStreamAsync("" + TitleNewsGrid.Text);
对我来说一切都很好,但是(对不起,这是我的第一个应用程序 ^^')当我编译时我发现了这个错误:
“System.Net.Http.HttpClient”不包含“TransportSettings”的定义