#1
|
|||
|
|||
Late Binding on SHDocVw
Code:
Option Explicit Public oIE As SHDocVw.InternetExplorer Public oSW As SHDocVw.ShellWindows Sub test() Set oIE = New SHDocVw.InternetExplorer Set oSW = New SHDocVw.ShellWindows oIE.Visible = True MsgBox oIE.LocationURL End Sub But I wonder how to do it in Late Binding, especially for SHDocVw.Internet Explorer and SHDocVw.ShellWindows. Code:
Dim oShell As Object, oShellWindows As Object Set oShell = CreateObject("Shell.Application") Set oShellWindows = oShell.windows |
#2
|
|||
|
|||
Code:
Option Explicit Public oIE As Object Public oSW As Object Sub test() Set oIE = CreateObject("InternetExplorer.Application") Set oSW = CreateObject("Shell.Application") For Each oIE In oSW.Windows MsgBox oIE.LocationURL Next End Sub |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Binding Problems? | tinfanide | Word VBA | 1 | 02-03-2012 06:15 AM |