|
本帖最后由 有阴也有阳 于 2018-12-22 12:50 编辑
请高手帮忙对以下关闭IE浏览器和资源管理器窗口的vbs脚本添加对360安全浏览器窗口的支持:
Set SHApp = CreateObject("Shell.Application")
Dim i,n
Dim win(100)
n=0
'Do
For Each SHWin In SHApp.windows
'WSH.Echo SHWin.FullName
'WSH.Echo SHWin.LocationURL
'WSH.Echo SHWin.LocationName
Set win(n)=SHWin
'SHWin.Quit
n=n+1
'If InStr(SHWin.LocationURL, "www.baidu.com") > 1 Then
' SHWin.Quit
'ElseIf SHWin.LocationURL = "file:///D:/" Then
' SHWin.Quit
'ElseIf SHWin.LocationURL = "file:///C:/" Then
' Exit Do
'End If
Next
'WSH.Sleep(1000)
'Loop
For i=0 To n - 1
win(i).Quit
Next
谢谢!!!
|
|