Create a simple python executable program and an i

2019-06-14 10:57发布

问题:

I am trying to create a simple python executable program - Hello World by following this link https://mborgerson.com/creating-an-executable-from-a-python-script.

The steps I took is first I create a python program, example: print("Hello, World!") I save this py program file into python script

C:\Users\d\AppData\Local\Programs\Python\Python35-32\Scripts

Then I install PyInstaller by going to command line point to directory python script and type

pip install PyInstaller

. After this, in command line I type

pyinstaller.exe --onefile --windowed helloWORLD.py

after putting the helloWORLD py program in the script folder. What happen after that is that it creates a

helloWORLD.exe

in script dist directory. However I can't run it. In vb.net I can run an executable program by double clicking on it. The second question, after being able to create the python executable program and run it; how do I create an icon for the python executable program. Thanks !