Hi, I am getting this error when I run my program. I do not have VB installed on this windows but it works fine on my other one. This is a fresh copy so I am pretty sure I am missing something. I am pretty sure the code that causes the crash is the following
Private Sub Terminate_All_IE()
Dim WMIObject As Object
Dim WMIObjectSet As Object
WMIObjectSet = GetObject("WinMgmts:").execquery("select * from Win32_process where name=IEXPLORE.EXE")
For Each WMIObject In WMIObjectSet
If WMIObject.Terminate = 0 Then
End If
Next
End Sub
It is suppose to close all IE windows but instead if gives me "Could not create an activex component"
Please help
Private Sub Terminate_All_IE()
Dim WMIObject As Object
Dim WMIObjectSet As Object
WMIObjectSet = GetObject("WinMgmts:").execquery("select * from Win32_process where name=IEXPLORE.EXE")
For Each WMIObject In WMIObjectSet
If WMIObject.Terminate = 0 Then
End If
Next
End Sub
It is suppose to close all IE windows but instead if gives me "Could not create an activex component"
Please help