System.Net.WebProxy.GetDefaultProxy Method

Reads the Internet Explorer nondynamic proxy settings.

Syntax

[System.MonoTODO("Can we get this info under windows from the system?")]
[System.Obsolete("This method has been deprecated", false)]
public static WebProxy GetDefaultProxy ()

Returns

A System.Net.WebProxy instance that contains the nondynamic proxy settings from Internet Explorer 5.5 and later.

Remarks

The WebProxy.GetDefaultProxy method reads the nondynamic proxy settings stored by Internet Explorer 5.5 and later, and creates a System.Net.WebProxy instance with those settings.

The WebProxy.GetDefaultProxy method does not pick up any dynamic settings that are generated from scripts run by Internet Explorer, from automatic configuration entries, or from DHCP or DNS lookups.

Applications should use the WebRequest.DefaultWebProxy property and the WebRequest.GetSystemWebProxy method instead of the WebProxy.GetDefaultProxy method.

Requirements

Namespace: System.Net
Assembly: System (in System.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0, 4.0.0.0