I am trying to consume third party web services from C# application. I have added their reference as service reference. Created the client from their reference using the url they given like below.
EndPointAddress endPointAddress = new EndPointAddress(new Uri("url here"));
SomeReportingClient client = new SomeReportingClient(binding, endPointAddress);
SomeReportingClient is their client class and binding is .net basicHttpBinding.
client.ClientCredentials.ClientCertificate.Certificate.SetCertificate("certificate subject name", StoreLocation.LocalMachine, StoreName.My);
After this code, the certificate is assigned very well no issues.
client.SomeMethod(request);
SomeMethod is the method in the webservice which i required to call. But in this line, the assigned certificate getting null immediately. The same code running in another machine.
Kindly help to resolve
Expecting to certificate should not get null and service call should be success.