Last active
December 27, 2015 10:49
-
-
Save frah/7313865 to your computer and use it in GitHub Desktop.
プロキシの設定を有効化するVBScript
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Option Explicit | |
Dim Excel, Com | |
Set Excel = WScript.CreateObject("Excel.Application") | |
Excel.Visible = False | |
rem HWND_BROADCAST = 0xffff | |
rem WM_SETTINGCHANGE = 0x001a | |
rem SMTO_NOMAL = 0x0 | |
Com = "CALL(""user32"",""SendMessageTimeoutA"",""JJJJJJJN"",""0xffff""," _ | |
& """0x001a"",0,0,0,1000)" | |
Excel.ExecuteExcel4Macro(Com) | |
Com = "CALL(""wininet.dll"",""InternetSetOptionA"",""AJJJJ"",0," | |
rem INTERNET_OPTION_SETTINGS_CHANGED = 39 | |
Excel.ExecuteExcel4Macro(Com & "39,0,0)") | |
rem INTERNET_OPTION_REFRESH = 37 | |
Excel.ExecuteExcel4Macro(Com & "37,0,0)") | |
Excel.Quit |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment