Activex events for InternetExplorer.Application

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Activex events for InternetExplorer.Application

drtau-4
I'm trying to catch events for InternetExplorer.Application, but not having
any luck.  My test code is as follows:

control := AXControlSite progId: 'InternetExplorer.Application'.
control firesControlEvents: true.
control when: #DocumentComplete:URL: send: #beep to: Sound.
control controlDispatch navigate: 'http://www.yahoo.com'.

If I use "Shell.Explorer" instead of "InternetExplorer.Application"
then it works.  However, the page that I get back when I call

control controlDispatch document documentElement outerHTML

is not the correct page for websites where the user must login
(e.g. hotmail).  Using "InternetExplorer.Application" gives me the
correct page, but I don't get the event notification when the
document has completed loading.  If I inspect the >>sink
for the control it's nil, whereas in the "Shell.Explorer" case
it's not.

Browsing the newsgroups it looks like it's very difficult to catch
events for "InternetExplorer.Application" even in VB.  I finally
came across this nugget of information that might help, but I'm
not sure how to incorporate this solution into Dolphin Smalltalk.
The URL for this info is:

http://www.devguru.com/Technologies/wsh/quickref/wscript_CreateObject.html

and it describes how to catch events for "InternetExplorer.Application"
in VBScript and JScript.  Can anyone help me adapt this solution
to Dophin?  Thanks very much.

P.S.  An alternative solution would be to try to get "Shell.Explorer"
to return the correct page.  Is it the case that I need to force it
to try to retrieve the page from the cache first?  Anyone know how
to do this?