【发布时间】:2012-05-29 17:58:04
【问题描述】:
我希望异步 HTTP 回调在 C# 中与 MSXML2 API 一起工作。我通过 winform 调用它。
x = new MSXML2.XMLHTTPClass();
x.open("POST", "http://localhost/MyHandler.ashx", true, null, null);
x.send("<test/>");
x.onreadystatechange = ???? //// What to specify here in C#?
var response = x.responseText; //// Works great synchronous!
我尝试了 Action()、匿名委托、匿名类型,但没有任何效果!可悲的是,在互联网上这个 VB.NET Module driven solution 存在,但我不确定如何在 C# 中完成。
任何帮助将不胜感激!
【问题讨论】:
标签: c# .net xmlhttprequest msxml4