我正在尝试从c#客户端访问网络服务器。我在C#客户端添加了webreference。 当我调用API时,我得到以下异常
"SOAPException was unhanded"
java.lang.NoSuchMethodException: com.dotv.server.api.soap.DimService.setUser(java.lang.String)
这里有什么线索错了吗?
代码:
WebReference.SLVDimmingServiceService service;
service = new WebReference.SLVDimmingServiceService();
service.Credentials = new System.Net.NetworkCredential("admin", "password");
service.setDimmingLevel("SC", "olc_7050_2.OLC[0]", (float)100.00);
例外:
System.Web.Services.Protocols.SoapException:java.lang.NoSuchMethodException:com.dotv.streetlightserver.api.soap.SLVDimmingService.setUser(java.lang.String)
at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message,WebResponse response,Stream responseStream,Boolean asyncCall)
at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName,Object [] parameters)
位于C:\ Users \ 310103448 \ Documents \ Visual Studio 2010 \ Projects \ testproject \ WindowsFormsApplication4 \ Web References \ WebReference \ Reference.cs中的WindowsFormsApplication4.WebReference.SLVDimmingServiceService.setDimmingLevel(String controllerStrId,String idOnController,Single dimmingLevel):第254行