#Convert python 3.6 to exe install
To upgrade it to the latest version, on command prompt, you will have to write pip install -upgrade setuptools. First, you have to write import sys if not written already, second, you have to make a variable for eg, location=getattr(sys,"_MEIPASS",".")+"/", third, the location of example.png would be location+"/example.png" if it is not in any folder.Ħ.) If it is showing any error, it may probably be because of a module called setuptools not being at the latest version. ico file instead of an image so to convert it, you can use ĥ.) If your script uses external files, you can add them through auto-py-to-exe and in the script, you will have to do some changes to their path.
#Convert python 3.6 to exe .exe
exe file and the screenshot of it is shared below. exe file ready.Ĥ.) There will be buttons for everything you need to make a. Also, closing command prompt will close auto-py-to-exe also so don't close it till you have your. It may take up to a minute the first time. You will have to press enter on command prompt to get the result of the line that you are typing.ģ.) Once it is installed, on command prompt itself, you can simply type just auto-py-to-exe to open it. exe file as you don't have to learn anything to use it.ġ.) It may not work for python 3.9 on some devices I guess.Ģ.) While installing python, if you had selected 'add python 3.x to path', open command prompt from start menu and you will have to type pip install auto-py-to-exe to install it.
The best and easiest way is auto-py-to-exe for sure, and I have given all the steps and red flags below which will take you just 5 mins to get a final. the imported packages must be installed before you start step 8.any name, any number, any description in setup.py file should not remain the same, you should change it accordingly (ex: name = "", version = "0.11", description = '' ).you should include each imported package in your.pyextension file name as created in step 4 be sure that instead of myfirstprog.py you should put your.Setup.py: from cx_Freeze import setup, ExecutableĮxecutables = Within that folder you can find your application. If your script is error free, then there will be no problem on creating application.In the prompt, type python setup.py build.
In the setup.py file, copy the code below and save it.Create a new python file named setup.py on the current directory of your script.Install idna, (open your command prompt and type pip install idna.Install cx_Freeze, (open your command prompt and type pip install cx_Freeze.