title: Calling SOAP web service programmatically
body: <p>I am consuming a SOAP web service from .NET code, by adding a reference to the service. Now the service wsdl endpoint might change in the future, so I want to add it to the config file in order to make my app more dynamic. Now I won't be able to use added reference anymore so I want to call the service from code without using service reference. I cannot create a <code>ChannelFacotry</code> as I do not have the interface type for the service as it is not WCF. So I cannot use something like this:</p>
  
  <pre><code>BasicHttpBinding binding = new BasicHttpBinding("MyBinding");
  EndpointAddress address = new EndpointAddress(baseUrl);
  
  ChannelFactory factory = new ChannelFactory&lt;IService&gt;(binding, address);
  </code></pre>
  
  <p>Is there any way I can consume SOAP web service without adding a service reference. And if not at all, is there any way for me to update the url of the ServiceReference dynamically from code?</p>