How to Enable and Disable proxy by script DOS command
Il seguente snippet spiega come abilitare e disabilitare il proxy di Internet Explorer mediante riga di comando.
E’ sufficiente creare i seguenti file di registro (enableProxy.reg):
Windows Registry Editor Version 5.00 [HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings] "ProxyEnable"=dword:00000001 "ProxyServer"="indirizzo_proxy:porta_proxy"
e (disableProxy.reg):
Windows Registry Editor Version 5.00 [HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings] "ProxyEnable"=dword:00000000
Infine bisogna create i file .bat che abilitano e disabilitano il proxy:
enableProxy.bat
@echo off regedit /s "C:\EnableDisableProxy\enableProxy.reg" start iexplore.exe
e disableProxy.bat
@echo off regedit /s "C:\EnableDisableProxy\disableProxy.reg" start iexplore.exe
Download snippet completo: EnableDisableProxy.zip (1,13 kb)
Enjoy snippet!
Lascia un commento