[python-win32] Re: getting a list of internet explorer instances?

Roger Upole rwupole at msn.com
Wed Jul 20 18:16:40 CEST 2005


import win32com.client
sw=win32com.client.Dispatch('{9BA05972-F6A8-11CF-A442-00A0C90A8F39}')
for w in sw:
    print w.LocationURL

The GUID represents the ShellWindows class, found in
the makepy file for "microsoft internet controls".

    hth
        Roger


"Marcus Goldfish" wrote:
> I've seen some posts on launching internet explorer, but not one on
> getting a list of running Internet Explorer instances.  I imagine this
> is a 1-2 liner in pywin32-- any COM/win32all experts out there know
> how to do this?
> 
> My goal is to write a script that can take a snapshot of the Internet
> Explorer instances running on my machine, pull the urls, and save them
> to a file.
> 
> Any help appreciated!
> Thanks,
> Marcus


More information about the Python-win32 mailing list