From: John M. <sjm...@le...> - 2006-08-30 05:43:13
|
On 30/08/2006 1:47 PM, Dick Moores wrote: > OK, I edited the path, adding E:\Python24\, and rebooted (did I need to?). No, you didn't need to reboot. > > This time, with both my app and setup.py in > E:\Python24\For_py2exe_setup.py, py2exe worked and created an exe that > worked. However, when I copied it to my desktop I found that all that > happened when clicking on it was a quick flash of some window. > The "dist" directory contains the files [plural] that need to be distributed. Copying the exe is not enough. You may wish to read the FAQ: http://www.py2exe.org/index.cgi/FAQ You may wish to put a *shortcut* to whatever.exe on your desktop; that will work, provided of course that the other files are in the same directory as the exe. > Then I thought I'd try a simple script, helloWorld.py . the exe was > created OK, but when moving it out of dist into any other folder, again > got that flashing window. Here's the script: > > ======================== > # Hello World! > print "Hello, World!" > > raw_input("\n\nPress the enter key to exit.") > ========================= > > I tried to run this at the command line, with these results: > > ============================= > E:\Python24\For_py2exe_setup.py\dist>helloWorld.exe > Hello, World! > > > Press the enter key to exit. > > E:\Python24\For_py2exe_setup.py\dist>cd.. > > E:\Python24\For_py2exe_setup.py>helloWorld.exe > LoadLibrary(pythondll) failedThe specified module could not be found. > > E:\Python24\For_py2exe_setup.py> > ============================= > (see way down below for what was printed during the creation of > helloWorld.exe) > > > Here's the command line result for 2 identical copies of 1keyPress-b5.exe: > > ========================== > E:\Python24\dist>1keyPress-b5.exe > > The program has started. > > press Space to get first and sub [snip] > > E:\Python24\Myscripts>1keyPress-b5.exe > LoadLibrary(pythondll) failedThe specified module could not be found. You may wish to raise an enhancement request for a more explicit error message. Evidently "pythondll" is a generic term, not the name of a particular file. > ======================================== > > > So it seems I need pythondll. I searched all of Python24, including > subfolders of course. No pythondll or python.dll . What to do? > Try typing ......\dist\1keyPress-b5.exe HTH, John |