Read and respond to this message at:
https://sourceforge.net/forum/message.php?msg_id=5064464
By: thornet
I've been having issues with getting eclipse to use the wxPython library.
First of all the python command shell imports and uses the library without any
problems.
Eclipse doesn't give an error when importing, but gives one when trying to use
anything inside the library.
For example, the following code work outside of eclipse:
import wx
app = wx.PySimpleApp()
frame = wx.Frame(None, -1, "Hello World")
frame.Show(1)
app.MainLoop()
But in eclipse the following errors are given:
Undefined variable from import: Frame
Undefined variable from import: PySimpleApp
What's most puzzling is when I run the following in eclipse:
for i in dir(wx):
print i
All the classes are printed out fine, including the Frame class that it claims
doesn't exist.
I've tried adding everything I can think of to the PYTHONPATH, but nothing
works.
Adding the wx folders, the wx.pth file, nothing works. I've tried searching
google and this forum, but no solutions have come up. Any ideas?
Thanks
______________________________________________________________________
You are receiving this email because you elected to monitor this forum.
To stop monitoring this forum, login to SourceForge.net and visit:
https://sourceforge.net/forum/unmonitor.php?forum_id=293649
-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
Pydev-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/pydev-users