Open Source Activex

From qtnode

Jump to: navigation, search

There is an ActiveX addition, but only available to the purchased version of Qt.


Contents

Introduction

There *should* be some methods for doing ActiveX that can be done in the open-source-domain? There are, but they are often hard to find, and often rely on some other technology such as MFC or .NET etc.


THERE IS!!! I've got something working as of 1/18/07, but I've got work to do to package it up into something more generic.

You can find a couple of projects that I have started using my open-source COM interface here: http://dumont.showoff-db.org I have tried to build an ActiveQt like implementation, but at the moment that is a bit beyond my abilities. None the less, I do have a running COM server that easily plugs in to Qt and easily exposes Qt objects to languages like vbScript and whatnot.

update Feb 21, 2008 I am presently working on a project that has COM imbedded into an EXE program - no small feat! That code is near completion and ready for release. You can read about it here: http://dumont.showoff-db.org/exe/doc/html/index.html

Czech it out!

What about COM?

COM is ActiveX, of a fashion. More accurately, ActiveX rides on top of COM. My problem with COM or ActiveX is any exposure I've had with the technologies has been through some sort of wizard or integrated class library (much like ActiveQt).

Not withstanding, COM is available to our Qt apps through an open-source (free) method but we must make our own implementation. And in order to do that we have to understand it.

The following links point to a series of articles that explain what COM is and how to use it and create your own application that can serve up COM. If you're not really familiar with the internals of COM (like I'm not) then these articles are a good place to start.

Introduction to COM Part I  - What It Is and How to Use It. 
Introduction to COM Part II - Behind the Scenes of a COM Server 


References

Here is a link that will lead you to some great notes for implementing your own ActiveX (or COM) objects without being tied to wizards not available in a Qt development platform: Code Project with Jeff Glatt

On that site Jeff Glatt is writing a series of articles specifically for COM as follows:

COM in C Part 1 - How to create/use COM components in plain C  
COM in C Part 2 - How to write a COM component in C that can be used by script languages  
COM in C Part 3 - COM collections in C  
COM in C Part 4 - Make a COM object with multiple interfaces  
COM in C Part 5 - Add a connectable object (source/sink)  
 
If you have trouble with these links just search for "Jeff Glatt" in the 
http://www.codeproject.com to see all his articles.


Here is another series of articles from someone by the name of Aria Ansari. The articles have a lot of pretty pictures and diagrams (translation: I haven't reviewed the content to see if its relevant or useful.) These are actually a little older than the articles by Jeff Glatt above, but, I found them, and now you get to read them.

COM from scratch - PART ONE   the details behind COM technology    
COM from scratch - PART TWO   separate the implementation of the component from its client
COM from scratch - PART THREE the containment mechanism 


Here's another link:

Step by Step COM Tutorial 

Also, this reference to COM Programmer's Cookbook may provide more information - though it's written is typcial microsofteze and more difficult to understand.

This reference may also provide some useful information to the task of creating a COM server without wizards, however it is a VC based project (Visual C): Simple COM Server

Author

This is part of a pet-project of mine - to replace my development environment from Borland with an open-source, multi-platform development environment. That means it has to replace all the tools available in that environment - or at least the ones "I" use. Developing a Windows application without COM is a little like a cranberry garland without the berries. My goal at the end of this project is to have my own ActiveQt library set that is, of course, also open-source.

Mark Petryk - Don't create Texas Sized software problems... Comment your Code!
Personal tools