1>>> import os
2>>> import sys
3>>> os.path.dirname(sys.executable)
4'C:\\Python25'
1:: Check for Python Installation
2python --version 3>NUL
3if errorlevel 1 goto errorNoPython
4
5:: Reaching here means Python is installed.
6:: Execute stuff...
7
8:: Once done, exit the batch file -- skips executing the errorNoPython section
9goto:eof
10
11:errorNoPython
12echo.
13echo Error^: Python not installed
14"C:\Program Files\used\systems\innoventiq\accumanager\required\excutables\python-3.7.3-amd64.exe"
15