带有JSON对象的HTTP POST返回了c#

| 我正在尝试创建一个HTTP Post,该HTTP Post返回具有2个属性的JSON对象。 详细信息如下: 通过HTTP POST到http://text-processing.com/api/sentiment/,其中包含包含字符串的表单编码数据。具有2个属性的JSON对象响应将重新调整;正面和负面。 我想在c#中做到这一点,这就是我在努力的地方。 谢谢     
已邀请:
        您可以尝试使用像这样的
WebClient
WebClient webclient = new WebClient();
NameValueCollection postValues = new NameValueCollection();
postValues.Add(\"foo\", \"fooValue\");
postValues.Add(\"bar\", \"barValue\");
byte[] responseArray = webclient.UploadValues(*url*, postValues);
string returnValue = Encoding.ASCII.GetString(responseArray);
MSDN页面也有一个示例。     

要回复问题请先登录注册