You may need to run the Proxycfg tool for ServerXMLHTTP to work
When you use ServerXMLHTTP code, and you do not run Proxycfg, or you do not restart IIS after the installation, you often receive one of the following error messages:
For additional information about the Proxycfgc tool, click the following article number to view the article in the Microsoft Knowledge Base:
Steps to configure WinHTTP for using ProxyCfg
- Make sure that ProxyCfg is in your System32 folder. If it is not, install one of the service packs or software that is mentioned earlier in this article.
- Determine the proxy server name (if any) that you use.
- At the command prompt, execute the proxycfg program with the settings that you want. Configure your computer by using the Proxy Config Utility.
- To see the current proxy settings for WinHTTP, type proxycfg By default this should be "Proxy Direct". If you have MSXML 3 sp1 or earlier, you may see that the settings say "Not Set". At this point, you MUST type proxycfg -d to set the default proxy settings for WinHTTP.
- To not use any proxy servers when connecting server-to-server, type proxycfg -d.
- To use a proxy server when connecting server-to-server, type proxycfg -p, and add to the line the list of proxy servers you want to use. Also, you can add optional bypass lists for servers that will not be accessed through a proxy. You can find acceptable proxy server formats or bypass formats in the ReadMe.txt file.
- To import the proxy information from WinInet and place them in the WinHTTP settings, type proxycfg -u
- Stop and restart Microsoft Internet Information Server (IIS).
- Example 1: proxycfg -d -p myProxyServer:80 "<local>"
This example shows the most common use for Proxycfg.exe. This command specifies that both HTTP and HTTPS servers must be accessed through the proxy server that is named "myProxyServer" with a port number of "80", unless the hostname does not contain a period. In this case, the -d option has no effect.
- Example 2: proxycfg -p myProxyServer
This example specifies that both HTTP and HTTPS servers need to be accessed through the proxy server that is named myProxyServer. It specifies no bypass list.
- Example 3: proxycfg -p "http=http_proxy https=https_proxy" "<local>;*.microsoft.com"
This example specifies that HTTP servers need to be accessed through the http_proxy proxy, and that HTTPS servers need to be accessed through https_proxy. Local intranet sites (for example, hostnames) that do not contain a period, and any site in the *.microsoft.com domain, bypass the proxy.
Article ID: 289481 - Last Review: 06/22/2014 11:04:00 - Revision: 5.0
- kbproductlink kbinfo kbmsxmlnosweep KB289481