Where is Word?

Tim Golden tim.golden at viacom-outdoor.co.uk
Tue Jun 14 06:18:47 EDT 2005


[Guy Lateur]
| Unfortunately, I need to open/edit a (temporary) text file 
| with Word, and 
| those are opened by default with UltraEdit (or Notepad or..). 
| Thanks for the 
| tip, though.
| 
| Anything else? Do I need to read the registry?
| 
| g

OK, you have a couple of options (at least). Easiest, probably
is to read the app paths from the registry.

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths

You're looking for winword.exe.

An alternative is to use WMI to interrogate the Win32_Product
classes and then to pick out the Software Elements etc. It's
a bit messy, so I'd stick to the the AppPath approach if I were you.

TJG

________________________________________________________________________
This e-mail has been scanned for all viruses by Star. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk
________________________________________________________________________



More information about the Python-list mailing list