1. 添加service:

Dynamic CRM 2013学习笔记(二十二)插件里调用WCF服务 

 

2.调用WCF

new BasicHttpBinding();
myBinding.Name = "BasicHttpBinding_IAuthService";
myBinding.Security.Mode = BasicHttpSecurityMode.None;
myBinding.Security.Transport.ClientCredentialType = HttpClientCredentialType.None;
myBinding.Security.Transport.ProxyCredentialType = HttpProxyCredentialType.None;
myBinding.Security.Message.ClientCredentialType = BasicHttpMessageCredentialType.UserName; 
 
EndpointAddress endPointAddress = new EndpointAddress("http://xxxx/AuthService.svc");
AuthServiceClient client = new AuthServiceClient(myBinding, endPointAddress);
return client.CheckDateAuth(auth);

相关文章:

  • 2021-10-02
  • 2022-12-23
  • 2021-08-04
  • 2022-01-05
  • 2021-11-25
  • 2021-10-21
  • 2022-01-29
  • 2021-12-05
猜你喜欢
  • 2022-02-24
  • 2021-06-12
  • 2021-08-05
  • 2022-01-15
  • 2021-09-01
  • 2021-06-20
相关资源
相似解决方案