On 10 Apr 2008, at 07:52, Kevin Horton wrote: > On 6 Apr 2008, at 20:50, Kevin Horton wrote: >> What are the simplest ways to make a double-clickable interface to a >> wxpython application? I don't need to actually include python or >> wxpython in the application, as they are already resident on her >> computer. > > I have stopped knocking my head against the wall with trying to find > a way to start this wxpython script by a double click. I have moved > the GUI portion to a Dashboard widget, and had it working in about 30 > minutes. The javascript in the widget calls the python script that > does the actual work. The widget provides the GUI. > > Thanks to everyone for their advice. It would have been nice to get > this working all in python, but I needed to cut my losses and move > on, as there are only so many hours in the day.
Here is a followup to close the loop on my problems. I eventually ran into a performance issue with my widget version, so I took another look at wxpython. With a fresh look, I realized that it was an environment issue that was causing the failure to start wxpython from an AppleScript or Automator. I have two scripts - the program is started by running the GUI script, which calls wx, and sets up the whole GUI. This script imports another script, which holds all the functions that perform the calculations that are the whole purpose of this application. The calculation script reads several data files, which live in the same directory as the two scripts. I was using relative paths when opening those data files. That worked fine if I started the script from the command line. But, for a reason that I don't yet understand, when using AppleScript, or Automator, I needed to use os.chdir() to point to the correct directory before loading the data files. The failure to load the data files did not trigger a traceback, or a Console message when the script was started with AppleScript. I had to resort to putting write statements in my script to log items of interest to a debug file before I could confirm the cause of the problem. Thanks for everyone's patience and assistance. Now that I am back with wxpython, I'll probably eventually have more questions as I beef up the functionality of this application. -- Kevin Horton RV-8 (FInal Assembly) Ottawa, Canada http://www.kilohotel.com/rv8 _______________________________________________ Pythonmac-SIG maillist - Pythonmac-SIG@python.org http://mail.python.org/mailman/listinfo/pythonmac-sig