[英]WP7 Restsharp POST result null
im trying to get RestShap working, but no luck so far. 我试图让RestShap工作,但到目前为止没有运气。 I havent really found any good documentation? 我还没有找到任何好的文件?
anyway, Should this work.. response.content is blank 无论如何,这应该工作.. response.content是空白的
private void webclienttest()
{
string query = @"<?xml blah blah...>;
var client = new RestClient("http://myurl.com");
var request = new RestRequest(query, Method.POST);
client.ExecuteAsync(request, (response) =>
{
var resource = response.Content;
PopulateList();
});
}
Your problem lies here: 你的问题在于:
client.ExecuteAsync (request, response =>
{
RestResponse resource = response;
var content = resource.Content;
PopulateList ();
});
You must use a RestResponse. 您必须使用RestResponse。
If it does not work, maybe it comes from your query or bad serialization. 如果它不起作用,可能它来自您的查询或错误的序列化。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.