Multiple versions of python

Nobody nobody at
Thu Jul 23 06:03:58 EDT 2009

On Tue, 21 Jul 2009 10:19:42 -0400, Dave Angel wrote:

> The other thing you may want to do in a batch file is to change the file 
> associations so that you can run the .py file directly, without typing 
> "python" or "pythonw" in front of it.
> The relevant Windows commands are:     assoc and ftype

However: assoc and ftype modify the registry keys under
HKLM\Software\Classes. This works fine if these are the only relevant
keys, but if you also have settings under HKCU\Software\Classes, those
will take precedence, so assoc and/or ftype won't have any effect.

Also, you typically need at least "Power User" status in order to modify
the keys under HKLM, while any user should be able to modify those under
HKCU (HKCU is a "virtual" key, corresponding to HKU\<interactive user>).

More information about the Python-list mailing list