I
iclinux
Using py2exe, I can convert a GUI Application with PythonCard to a
standalone windows program, and it works.
Then I try another GUI Toolkit named Wax, implement a GUI App, it
works. And I convert that app by py2exe. But this time, when run, it
show a messagebox that says:
"""
This application requires a version of wxPython greater than or equal
to 2.6, but a matching version was not found.
You currently have these version(s) installed:
Would you like to download a new version of wxPython?
"""
any suggestion?
the follows are the code of setup.py and the GUI App test.py.
///////////////////////////////////////////////////////////////////////////////////////////////
#setup.py
from distutils.core import setup
# py2exe stuff
import py2exe, os
setup(name='test',
version='0.1',
url='about:none',
author='anonymous',
author_email='[email protected]',
package_dir={'test':'.'},
packages=['test'],
windows=['test.py'],
)
///////////////////////////////////////////////////////////////////////////////////////////////
# test.py
import sys
sys.path.append("../..")
from wax import *
WaxConfig.default_font = ("Verdana", 9)
class MainFrame(Frame):
def Body(self):
self.AddComponent(Button(self, "one", event=self.OnClick))
self.Pack()
def OnClick(self, event=None):
# show an empty dialog... ugly, but it should work
dlg = Dialog(self, "JUst some dialog")
print dlg.OnCharHook
print dlg.ShowModal()
dlg.Destroy()
app = Application(MainFrame)
app.MainLoop()
///////////////////////////////////////////////////////////////////////////////////////////////
standalone windows program, and it works.
Then I try another GUI Toolkit named Wax, implement a GUI App, it
works. And I convert that app by py2exe. But this time, when run, it
show a messagebox that says:
"""
This application requires a version of wxPython greater than or equal
to 2.6, but a matching version was not found.
You currently have these version(s) installed:
Would you like to download a new version of wxPython?
"""
any suggestion?
the follows are the code of setup.py and the GUI App test.py.
///////////////////////////////////////////////////////////////////////////////////////////////
#setup.py
from distutils.core import setup
# py2exe stuff
import py2exe, os
setup(name='test',
version='0.1',
url='about:none',
author='anonymous',
author_email='[email protected]',
package_dir={'test':'.'},
packages=['test'],
windows=['test.py'],
)
///////////////////////////////////////////////////////////////////////////////////////////////
# test.py
import sys
sys.path.append("../..")
from wax import *
WaxConfig.default_font = ("Verdana", 9)
class MainFrame(Frame):
def Body(self):
self.AddComponent(Button(self, "one", event=self.OnClick))
self.Pack()
def OnClick(self, event=None):
# show an empty dialog... ugly, but it should work
dlg = Dialog(self, "JUst some dialog")
print dlg.OnCharHook
print dlg.ShowModal()
dlg.Destroy()
app = Application(MainFrame)
app.MainLoop()
///////////////////////////////////////////////////////////////////////////////////////////////