Configuring proxy through batch file [Solved/Closed]

-
Hello,
hi, I have created one batch file to add dns server detail automatically with the netsh command.
i want to configure the proxy details in Internet explorer so that I dont need to go to internet options-connection-lan setting-then proxy server optiop I can configure it by batch file.

thanks in advance

Regards
Rajesh
See more 

1 reply

Best answer
approved by Jean-François Pillou on Apr 19, 2011
Posts
12
Registration date
Saturday January 3, 2009
Last seen
June 15, 2009
8
Thank you
Hello,

I have found the solution to the problem:

Put this in a .vbs file. double click the file to run it.

dim oShell
set oShell = Wscript.CreateObject("Wscript.Shel  l")

if msgbox("Turn Proxy on?", vbQuestion or vbYesNo) = vbYes then
oShell.RegWrite "HKCU\Software\Microsoft\Windows\C  urrentVersion\Internet Settings\ProxyEnable", 1, "REG_DWORD"
oShell.RegWrite "HKCU\Software\Microsoft\Windows\C  urrentVersion\Internet Settings\ProxyServer", "proxy:8080", "REG_SZ"
else
oShell.RegWrite "HKCU\Software\Microsoft\Windows\C  urrentVersion\Internet Settings\ProxyEnable", 0, "REG_DWORD"
end if

Set oShell = Nothing

Say "Thank you" 8

A few words of thanks would be greatly appreciated. Add comment

CCM 2933 users have said thank you to us this month

Please also suggest how to incorporate in the Internet shortcut "Target Path" command line.

So whenever I open the internet explorer from that shortcut, it sets up proxy.
Thnaks a lot...working fine
Thanks dear. It helped
Thank you!!! Exactly what I needed!
Saved my day as i needed to manually set proxy every 30 mins.. Thanks a ton!!!