WebApi登陆报错
金蝶云社区-wu9531
wu9531
1人赞赏了该文章 1,158次浏览 未经作者许可,禁止转载编辑于2016年02月16日 17:10:37

Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
ApiClient client = new ApiClient("http://localhost/k3cloud/");
bool result = client.Login("AIS20141106174715", "user", "888888", 2052);//第一个参数用数据库实体/数据中心代码都试过了,都报错

未处理Kingdee.BOS.WebApi.Client.ServiceException
_HResult=-2147467259
_message=外部组件发生异常。
HResult=-2147467259
IsTransient=false
Message=值不能为 null。
参数名: dcInfo
Source=Kingdee.BOS.ServiceFacade.KDServiceFx
ErrorCode=-2147467259
WebEventCode=0
ClassName=Kingdee.BOS.ServiceFacade.ServiceException
ExceptionMethod=8
Execute
Kingdee.BOS.ServiceFacade.KDServiceFx, Version=5.1.250.5, Culture=neutral, PublicKeyToken=null
Kingdee.BOS.ServiceFacade.KDServiceFx.ServiceExecutor
System.String Execute(Kingdee.BOS.ServiceFacade.KDServiceFx.KDServiceContext, Kingdee.BOS.ServiceFacade.KDServiceFx.ServiceType, System.String[], Kingdee.BOS.ServiceFacade.SerializerProxy, Kingdee.BOS.ServiceFacade.KDServiceFx.ServiceType)
Handled=false
StackTrace:
在 Kingdee.BOS.ServiceFacade.KDServiceFx.ServiceExecutor.Execute(KDServiceContext context, ServiceType svcType, String[] paraValues, SerializerProxy serializeProxy, ServiceType beginMethod)
在 Kingdee.BOS.ServiceFacade.KDServiceFx.ExecuteServiceModule.OnProcess(KDServiceContext context)
在 Kingdee.BOS.ServiceFacade.KDServiceFx.ModulePipeline.ExcuteRequest(KDServiceContext context)
在 Kingdee.BOS.ServiceFacade.KDServiceFx.RequestExcuteRuntime.StartRequest(RequestExtractor requestExtractor, WebContext context)
在 Kingdee.BOS.ServiceFacade.KDServiceFx.KDSVCHandler.ExecuteRequest(WebContext ctx, RequestExtractor requestExtractor)
在 Kingdee.BOS.ServiceFacade.KDServiceFx.KDSVCHandler.ProcessRequestInternal(WebContext webCtx, RequestExtractor requestExtractor)
InnerException: