Here's the code:
code:
$ = SetConsole("MINIMIZE")
$ = SetConsole("HIDE")
Break on
$rc = MessageBox("Sluit alle andere Internet Explorer vensters."+
@crlf+"Na 2 minuten òf na het klikken op OK, worden ze automatisch gesloten!",
"KiXtart message",49,120)
If 2 = $rc
Exit 0
EndIf
Shell "%comspec% /c @scriptdir\kill95 iexplore.exe > nul"
$proxy = ReadValue("HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings",
"ProxyEnable")
$ = WriteValue("HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings",
"ProxyEnable","1","REG_DWORD")
$ = WriteValue("HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings",
"ProxyOverride","10.*.*.*","REG_SZ")
$ = WriteValue("HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings",
"ProxyServer",";http=PROXYSERVER","REG_SZ")
$ = WriteValue("HKCU\Software\Policies\Microsoft\Internet Explorer\Restrictions",
"NoFileOpen","1","REG_DWORD")
$ = WriteValue("HKCU\Software\Policies\Microsoft\Internet Explorer\Restrictions",
"NoFileNew","1","REG_DWORD")
$ = WriteValue("HKCU\Software\Policies\Microsoft\Internet Explorer\Restrictions",
"NoFindFiles","1","REG_DWORD")
$ = WriteValue("HKCU\Software\Policies\Microsoft\Internet Explorer\Restrictions",
"NoTheaterMode","1","REG_DWORD")
$ = WriteValue("HKLM\Software\Policies\Microsoft\Internet Explorer\Infodelivery\Restrictions",
"NoSplash","1","REG_DWORD")
$ie = CreateObject("internetexplorer.application")
$ie.addressbar = 0
$ie.menubar = 0
$ie.statusbar = 0
$ie.toolbar = 0
$ie.resizable = 0
$ie.Left = 10
$ie.top = 10
$ie.width = 1000
$ie.height = 700
$ie.navigate("about:blank")
While $ie.busy AND $ie.readystate <> 4 AND @error=0 Loop
$ie.visible=1
$ie.navigate("http://URL_TO_GO_TO")
While $ie.busy AND $ie.readystate <> 4 AND @error=0 Loop
$ = WriteValue("HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings",
"ProxyEnable",$proxy,"REG_DWORD")
Kill95 is the one from helpdesk.kixtart.org (if I remember correctly) and this is giving me the command box.
I run this script with "wkix32 /i"
WMI can't be used as it's not started... Starting also displays the box.
*** Gonna catch my train so will read your replies tomorrow... ***