BasicHttpBinding.ProxyAddress Property


Gets or sets the URI address of the HTTP proxy.

 property Uri ^ ProxyAddress { Uri ^ get(); void set(Uri ^ value); };
public Uri ProxyAddress { get; set; }
public Uri ProxyAddress { get; set; }
member this.ProxyAddress : Uri with get, set
Public Property ProxyAddress As Uri

Property Value


A Uri that serves as the address of the HTTP proxy. The default value is null.



The following example sets ProxyAddress to application settings.

// Get base address from app settings in configuration
Uri baseAddress = new Uri(ConfigurationManager.AppSettings["baseAddress"]);

BasicHttpBinding binding = new BasicHttpBinding();

binding.ProxyAddress = baseAddress;

The value of this property can also be set in the configuration file.


        <binding name="Binding1"
                 proxyAddress = "http://myProxy">
          <security mode="None" />




If the UseDefaultWebProxy is set to true, the default address is used and the value of the ProxyAddress set is ignored.

Applies to