Emnico in Swindon and its partners
in the UK and Europe provide:

» IT Support Services and Products
» Bespoke Software Development


Contact our Swindon office on:
+44 (0)1793 614 700
to discuss your IT needs.


CLOSE IT
Emnico Logo
Your Virtual Technology Team
Delivering Peak Performance
Category: Type: Order:
Search For:  
Home > Library > Toggle Proxy Settings

Toggle Proxy Settings

This script will toggle the HTTP proxy settings in Internet Explorer.
Added 276 days ago by Emnico
Download
Review
Back
55Views
This script has been successfully tested by Emnico and is verified to be working.

Source code

Const HKEY_CURRENT_USER = &H80000001

strComputer = "."
Set objRegistry = GetObject("winmgmts:\\" & strComputer & "\root\default:StdRegProv")
 
strKeyPath = "SOFTWARE\Microsoft\Windows\CurrentVersion\Internet Settings"
strValueName = "ProxyEnable"

objRegistry.GetDWORDValue HKEY_CURRENT_USER, strKeyPath, strValueName, dwValue

if dwValue = 1 then 
  dwValue = 0
  objRegistry.SetDWORDValue HKEY_CURRENT_USER, strKeyPath, strValueName, dwValue
  Wscript.Echo "Proxy Off"
else
  dwValue = 1
  objRegistry.SetDWORDValue HKEY_CURRENT_USER, strKeyPath, strValueName, dwValue
  Wscript.Echo "Proxy On"
end if


| Privacy policy | Environmental policy | Site map |