This is a newbie question. I am having trouble getting wxPython to run.
Under windows98, I have installed Active Python 2.2 which seems to be
working fine.
I have downladed the prebiult binary for wxWindows 2.4.0.
I have installed wxPython in the directory "c:\active22\.
I have added "set wxpython=c:\active22", to autoexec.bat.
Printing "sys.path", shows "c:\active22" as one of the directories in the
Python path.
When I try to run code such as...
from wxPython.wx import *
class MyApp(wxApp):
def OnInit(self):
frame = wxFrame(NULL, -1, "Hello from wxPython")
frame.Show(true)
self.SetTopWindow(frame)
return true
app = MyApp(0)
app.MainLoop()
I get the error message....
File
"C:\Python22\Lib\site-packages\Pythonwin\pywin\framework\scriptutils.py",
line 301, in RunScript
exec codeObject in __main__.__dict__
File "C:\Usr\george\wxpy\tut01.py", line 1, in ?
from wxPython.wx import *
ImportError: No module named wxPython.wx
If I enter "import wxpython" from the interactive window, I get...
Traceback (most recent call last):
File "<interactive input>", line 1, in ?
ImportError: No module named wxpython
It seems that I can't get Python to find the wxPython module.
I belive the the correct directory appears in both Python Path and in wxwin.
My small brain is confused... and getting smaller!
As a pre-requisite to use xwWindows, a copiler is listed.
Having dowloaded a binary, I assumed that it would be ready to run. Is this
correct?
Can I run code that calls wxWindows under the'interperter',
or must the code be compiled first? Presently, I don't want to create .EXE
files.
Any suggestions would be both humbley and gratefully appreciated.
Thanks,
George
···
--------------------------------------------------------------------
mail2web - Check your email from the web at
http://mail2web.com/ .