|
-
Feb 15th, 2001, 05:56 AM
#1
Thread Starter
Junior Member
I'm using a gobal mouse hook, whenever there is mouse click, CaptureData () method will be called. The problem comes when i try to do something to the objIE1, i get a Runtime error '-2147417843(8001010d)' Automation Error. What did i do wrong?
Public Sub CaptureData()
Set objShellWins = New SHDocVw.ShellWindows
On Error GoTo cap
Dim objIE1 As SHDocVw.InternetExplorer
If isForegroundIE = True Then
Debug.Print "Current is IE"
For Each objIE1 In objshellwindows
'this is the code that gives mi error
Debug.Print objIE1.hwnd
Next objIE1
Exit Sub
cap:
Debug.Print Err.Number & " " & Err.Description
End If
End Sub
-
Feb 15th, 2001, 03:27 PM
#2
Lively Member
try using:
on error resume next
and seeing if it can just skip over ther error, and still work.
Seems like it might work,
Bios
Age: 17
Languages: (Q)BASIC, Visual Basic, Dark Basic,C/C++, Visual C++, Perl, Java Script, HTML, ASP
"DO:BEEP:LOOP"
-
Feb 15th, 2001, 09:07 PM
#3
Thread Starter
Junior Member
Yes it works, thanks, but doesnt really solve my problem© I'm trying to loop through ShellWindows to check which Internet Explorer handle is equal to the foregroundWindow handle then assign objIE to it© The moment i try to do something with the objIE, i get an automation error© How can i solve this??
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|