ActiveX Questions

Chris Tavares christophertavares at earthlink.net
Tue Feb 19 15:17:40 EST 2002


"Chris Gonnerman" <chris.gonnerman at newcenturycomputers.net> wrote in message
news:mailman.1014094712.4434.python-list at python.org...
> ----- Original Message -----
> From: "Jeff Shannon" <jeff at ccvcorp.com>
> >
> > Michael Kelly wrote:
> > >
> > > Out of curiosity, did they give you a type library
> > > with the control?
> >
> > This is important.  As I understand it, without a type library,
pythoncom
> > has no way of knowing which params are [out] params.  Since Python
doesn't
> > have reference semantics like those of C++ or Visual Basic, it cannot
use
> > [out] params in the "normal" way.  So if you're using an interface that
> > makes use of [out] params, you *need* the type library in order to be
able
> > to use it from Python.  If you're not sure whether you've got one, try
> > Makepy, as suggested...
>
> Type libraries have a .tlb extension normally, correct?  The ZIP contains
> ReportOcx.lic, .lib, and .ocx; I'm a novice at Windows and had to be
banged
> on the head before I put the .lic and .ocx together in the SYSTEM folder.
> I did register the OCX using REGSVR32 as noted on several websites, and I
> ran makepy from the Pythonwin menu as I have in several other instances.
>
> Have I missed anything?
>

Type libraries are often compiled right into the control they're for. Try
running makepy on the OCX file.

> The source files are not available (it's a form of shareware, where you
pay
> for source access) so I can't build a type library even if I knew how.
>
> I should just go back to Linux where everything makes sense...

Linux doesn't make any more sense than Windows, it's just a different kind
of sense. :-)

-Chris






More information about the Python-list mailing list