如果webservice在本地测试可以运行,(若有参数)且能输入参数调用。而在远程却显示“测试窗体只能用于来自本地计算机的请求”或者"The test form is only available for requests from the local machine. ",那是因为没有开启远程访问的原因。解决办法如下:
在web.config的<system.web></system.web>中间加入如下配置节内容
<webServices>
<protocols>
<add name="HttpSoap"/>
<add name="HttpPost"/>
<add name="HttpGet"/>
<add name="Documentation"/>
</protocols>
</webServices>