2012-05-18 139 views

回答

0

根据您的要求,最好的方法是使用HttpWebRequest。你可以只写一些像这样的代码来完成表单发布:

string url = "http://www.myserver.com/mypage.php?param1=abc&param2=123"; 
var request = (HttpWebRequest)HttpWebRequest.Create(url); 
request.Method = "POST"; 
var response = (HttpWebResponse)request.GetResponse(); 
// etc... read the response from the server here, if you need it 
+0

非常感谢。奇迹般有效 :) –

0

在Windows Vista和更高版本,服务使用非交互式窗口站,不能与用户交互。阅读here了解更多信息。