Tuesday, September 29, 2020

MSCRM+ on premise plugin error + could not find default endpoint element that references contract

 Hi All,


If you get error with could not find default endpoint element that references contract


while trying in Plugins or Workflow Activity

Please use below code in your code


BasicHttpBinding myBinding = new BasicHttpBinding();

                myBinding.Name = "BasicHttpBinding_Service";

                myBinding.Security.Mode = BasicHttpSecurityMode.None;

                myBinding.Security.Transport.ClientCredentialType = HttpClientCredentialType.None;

                myBinding.Security.Transport.ProxyCredentialType = HttpProxyCredentialType.None;

                myBinding.Security.Message.ClientCredentialType = BasicHttpMessageCredentialType.UserName;


                // Endpoint Address defining the asmx Service to be called.

                EndpointAddress endPointAddress = new EndpointAddress(@"http://yourwebservice.com/sms_ws/Service.asmx");


                // Call to the Web Service using the Binding and End Point Address.

                SendSMS.ServiceSoapClient myClient = new SendSMS.ServiceSoapClient(myBinding, endPointAddress);

No comments:

Post a Comment

Dataverse/MSCRM: Work with Masking Rule

  Introduction: In this blog, we will see how to work with Masking Rule in MSCRM or Dataverse. Issue : I don't want to show the Email va...