In my computer has already installed python 3.11.4 and python 3.12 (latest version).
But provided path in "Edit the system environment variable" 3.12 only.
(Unchecked "Add Python 3.11 to PATH" check box when Install Python 3.11.4)
I need to create virtual environment for some project by using python 3.11 version.
So, that’s why I installed 3.11.4 version too.
After that, I tried to create virtual environment with execute the following command in CMD :
python3 -m venv --python=C:\Python\Python311 MyVenv
(And also tried with this command 🙂
python3.11 -m venv MyVenv
But it gave me Error as follows :
Python was not found; run without arguments to install from the Microsoft Store,
or disable this shortcut from Settings > Manage App Execution Aliases.
When I try to create VENV by using 3.12 version It was successfully created !
Q :
How to control multi-version of python same local machine ?
How to create VENV with my prefer virsion in multi-version installed machine ?
>Solution :
Use this Command for 3.11 :
C:\Python\Python311\python.exe -m venv MyVenv