Aug-28-2018, 05:42 AM
(Aug-27-2018, 02:47 PM)snippsat Wrote:now i have syntax error on off in @echo off. rippy.exe
get installed in Windows folder when install Python37. Can be used to accessing previous version or current,can also install withpip
to all version installed. Example:# Python version set in Windows Path C:\>python -V Python 3.7.0 # Can also access with py C:\>py -3.7 -V Python 3.7.0 # Older version i have C:\>py -2.7 -V Python 2.7.9 C:\>py -3.4 -V Python 3.4.2 C:\>py -3.5 -V Python 3.5.2 C:\>py -3.6 -V Python 3.6.4Usepy
to install withpip
to eg 2.7.λ py -2.7 -m pip install logzero Requirement already satisfied: logzero in c:\python27\lib\site-packagesMaking bathello.bat
. Usepython
main version,pause
in bat so cmd window doesn't close immediately. Can also put this last in codeinput('Press Enter to exit')
.@echo off python C:/foo/hello.py %* pauseIf want to run 2.7 in a bat file,then usepy
.@echo off py -2.7 C:/foo/hello.py %* pause