Hi guys, I am using XMLHTTP object to send an http request. I want to send the HTTP request using different proxies, so I made a sub that is called and passed different proxy server names to test.
sub testSite(url, proxy)
Set objHTTP = CreateObject("MSXML2.XMLHTTP")
objHTTP.open "GET", url, false
objHTTP.send
msgbox objHTTP.responseText
set xmlhttp = nothing
end sub
using the XMLHTTP object, I cannot figure out if there is a way to tell the request to use a specific proxy (like xmlhttp.proxy = proxy). Right now it uses the currently configured proxy settings in IE for the machine that executes the script.
If there isn't a way to specify the proxy to use, it looks like I will have to dynamically change the setting within IE via the registry, but that will be much slower.
sub testSite(url, proxy)
Set objHTTP = CreateObject("MSXML2.XMLHTTP")
objHTTP.open "GET", url, false
objHTTP.send
msgbox objHTTP.responseText
set xmlhttp = nothing
end sub
using the XMLHTTP object, I cannot figure out if there is a way to tell the request to use a specific proxy (like xmlhttp.proxy = proxy). Right now it uses the currently configured proxy settings in IE for the machine that executes the script.
If there isn't a way to specify the proxy to use, it looks like I will have to dynamically change the setting within IE via the registry, but that will be much slower.