import wx.lib.activex fails

Hi I’m trying to run an ActiveX example I found online, but “import wx.lib.activex” is failing (stack trace here)… It appears to fail on loading myole4ax which doesn’t exist (at least there’s nothing like this in C:\Python27\Lib\site-packages\wx\lib). Is there something else I’m supposed to do to generate this file? I read here something about running a demo and playing asteroids, however I’m not sure where to find this demo or if it’ll help my situation.

I’m running Python 2.7.3 via Enthought Distribution on Windows 7 (have tried both 32-bit/64-bit versions)

My wx is at version 2.8.10.1 and comtypes is at 0.6.2

All help much appreciated!

After digging around more, the problem appears to be limited to the version of wx supplied with the Enthought Distribution, which appears to be different from the main version somehow…
Installing Wx python 2.8 from here solved this problem, however that seems to break the ipython + pylab shell… it starts complaining the version needs to be >= 2.8 which is strange because it is >= 2.8.

···

On Tuesday, September 24, 2013 10:12:42 PM UTC+9, Tim ティム wrote:

Hi I’m trying to run an ActiveX example I found online, but “import wx.lib.activex” is failing (stack trace here)… It appears to fail on loading myole4ax which doesn’t exist (at least there’s nothing like this in C:\Python27\Lib\site-packages\wx\lib). Is there something else I’m supposed to do to generate this file? I read here something about running a demo and playing asteroids, however I’m not sure where to find this demo or if it’ll help my situation.

I’m running Python 2.7.3 via Enthought Distribution on Windows 7 (have tried both 32-bit/64-bit versions)

My wx is at version 2.8.10.1 and comtypes is at 0.6.2

All help much appreciated!

Tim ティム wrote:

After digging around more, the problem appears to be limited to the
version of wx supplied with the Enthought Distribution, which appears to
be different from the main version somehow...

I haven't checked yet but I'm guessing that they have simply left out the myole4ax.* files in wx/lib. Try copying them from the stock wxPython into Enthought's wxPython installation.

···

--
Robin Dunn
Software Craftsman

Thanks, I had initially naively tried searching for these files with google and got them from the below repository when I first started problem solving, which didn’t work.
https://github.com/wxWidgets/Phoenix/blob/master/wx/lib/myole4ax.tlb

After reading your message above, I downloaded the wxPython-src tarball from the project page, then copied the two myole4ax.* files from (wxPython-src-2.8.12.1\wxPython\wx\lib) to the python (\site-packages\wx\lib) folder and this worked fine.

Thanks for your help.

···

On Thursday, September 26, 2013 4:16:47 AM UTC+9, Robin Dunn wrote:

Tim ティム wrote:

After digging around more, the problem appears to be limited to the

version of wx supplied with the Enthought Distribution, which appears to

be different from the main version somehow…

I haven’t checked yet but I’m guessing that they have simply left out
the myole4ax.* files in wx/lib. Try copying them from the stock
wxPython into Enthought’s wxPython installation.


Robin Dunn

Software Craftsman

http://wxPython.org