使用受invincea保护的Internet Explorer窗口

时间:2015-08-11 17:09:20

标签: internet-explorer

我有一个通常适用于Internet Explorer的脚本,但是,因为该公司提供了一个名为" Invincea"在每个人的计算机上,似乎脚本无法读取窗口标题。有什么建议吗?

没有Invincea的IE的先前代码:

URL = "http://nameofmysite.com"
Window = "My Site"

Set objShell = CreateObject("Shell.Application")
Set WShell = CreateObject("WScript.Shell")
URLFound = False
Set objShellWindows = objShell.Windows
    'To Fix Item Not Found Error
For Each objIE In objShell.Windows
Next

For I = 0 To objShellWindows.Count - 1
    Set objIE = objShellWindows.Item(I)
    On Error Resume Next
    If InStr(UCase(objShellWindows.Item(I).FullName), "IEXPLORE.EXE") Then
       If Err.Number = 0 Then
          If InStr(objShellWindows.Item(I).Document.Title, (Window)) Then
             URLFound = True
             Exit For
          End If
       End If
    End If
Next

如果IE受Invincea保护,此代码不起作用。我改变了代码,认为它会起作用,但它没有:

URL = "http://nameofmysite.com"
Window = "My Site - Protected by Invincea"

希望有人遇到过这个问题。

0 个答案:

没有答案