What line of text should I put at the top of script.py to invoke the specific version of Python that I need to use?
I have two versions of Python for Windows XP, 2.6.5 and 2.7.2. Each of them has its own special modules and has been installed by separate applications. My scripts are placed on the desktop, so I can double-click and run them conveniently.
The problem is that all my scripts call 2.6.5, which is great for scripts that use modules installed with 2.6.5, but my scripts designed for 2.7.2 do not run. They call Python 2.6.5 without the modules I need to import.
I tried to print various headers with and without #! call 2.7.2 when I need it, but either my syntax is incorrect or it is simply impossible to specify under Windows. Can someone tell me the exact syntax of the string I need to add to my script. The python.exe file for 2.7.2 is stored in the folder C: \ OSGeo4W \ bin
Thanks for letting me know which line to put at the top of script.py in order to invoke the exact version of Python that I should use.
user12711
source share