(Slightly OT) General ActiveX information? 
Author Message
 (Slightly OT) General ActiveX information?

Hi all,

I've bought a bunch of books lately on COM and ATL (Inside COM,
Effective COM, ATL Internals, the Grimes books, etc). That's a lot of
information on ATL and COM, but one thing I can't remember coming
across is information on ActiveX itself. I assume that an ActiveX
control is just a COM component that implements a number of specific
interfaces, or something along those lines, but I haven't found
anything detailing this.

For example, I've written 3 perfectly functional ActiveX components in
ATL for a Web site I'm coding. The code is pure pasta - a lot of it's
shared, and I've accomplished code reuse through cut-n-paste. I'd like
to put the shared code into a number of smaller COM components, and
then build my 3 larger controls from these. But I can't find anything
on how an ActiveX control would register COM components that it's
composed of. Do my high level ActiveXs have to 'manually' install
them? Do they low-level components have to be ActiveX? Is there an
'IInstallable' interface or something like that?

Another issue: I'd like my ActiveX components to live from one Web
page to another. Who wouldn't? I don't know that I care about
persistence so much as I'd rather the DLLs weren't loaded and unloaded
all the time. Is there an IDontKillMe interface for this?

Beyond answering these questions, what I'm really after is a book
that'll let me answer them for myself. Actually a site would be better
- I've about blown my book budget already.

Thanks a lot,
Chris



Fri, 14 Nov 2003 22:05:34 GMT  
 (Slightly OT) General ActiveX information?
You won't find much about ActiveX because that is a fictitious term.
What it means is usually either ActiveX Controls or Automation.
(Some mean the COM DLLs produced by VB, BTW...) So don't bother
looking further...

You can achieve code reuse on the source level as well - no need
to go binary. All you have to do is bundle all the top-level controls
in a single DLL (as MS did with the common controls for example).
Then the whole arsenal of C++ is at your disposal. I usually
recommend source code reuse over COM binary reuse.

For the last question - you may be interested in the so called
Browser Helper Objects (BHO) in IE 4 and above. Search on MSDN
and you'll find some articles...

--
=====================================
Alexander Nickolov
Microsoft MVP [VC], MCSD

MVP VC FAQ: http://www.mvps.org/vcfaq
=====================================


Quote:
> Hi all,

> I've bought a bunch of books lately on COM and ATL (Inside COM,
> Effective COM, ATL Internals, the Grimes books, etc). That's a lot of
> information on ATL and COM, but one thing I can't remember coming
> across is information on ActiveX itself. I assume that an ActiveX
> control is just a COM component that implements a number of specific
> interfaces, or something along those lines, but I haven't found
> anything detailing this.

> For example, I've written 3 perfectly functional ActiveX components in
> ATL for a Web site I'm coding. The code is pure pasta - a lot of it's
> shared, and I've accomplished code reuse through cut-n-paste. I'd like
> to put the shared code into a number of smaller COM components, and
> then build my 3 larger controls from these. But I can't find anything
> on how an ActiveX control would register COM components that it's
> composed of. Do my high level ActiveXs have to 'manually' install
> them? Do they low-level components have to be ActiveX? Is there an
> 'IInstallable' interface or something like that?

> Another issue: I'd like my ActiveX components to live from one Web
> page to another. Who wouldn't? I don't know that I care about
> persistence so much as I'd rather the DLLs weren't loaded and unloaded
> all the time. Is there an IDontKillMe interface for this?

> Beyond answering these questions, what I'm really after is a book
> that'll let me answer them for myself. Actually a site would be better
> - I've about blown my book budget already.

> Thanks a lot,
> Chris



Sun, 16 Nov 2003 10:44:21 GMT  
 (Slightly OT) General ActiveX information?

Quote:
>You won't find much about ActiveX because that is a fictitious term.
>What it means is usually either ActiveX Controls or Automation.
>(Some mean the COM DLLs produced by VB, BTW...) So don't bother
>looking further...

Hmmmmm. Always nice to know that a term doesn't really mean anything.
I remember making the same discovery about Java Beans about 4 years
ago - killing myself reading white papers & specs to answer the
question "What IS a bean" - then determining that basically there's no
such thing.

I guess then that what I care about are ActiveX controls. I assume
this is a term with some meaning, inasmuch as browsers are going to
download & maniuplate them in some defined away. Is there somewhere to
learn about this?

Quote:
>You can achieve code reuse on the source level as well - no need
>to go binary. All you have to do is bundle all the top-level controls
>in a single DLL (as MS did with the common controls for example).
>Then the whole arsenal of C++ is at your disposal. I usually
>recommend source code reuse over COM binary reuse.

This sounds like a good idea that I would understand if I were better
at this stuff. I *think* what you're saying is that I can go ahead and
compile all my components - top level, low level, whatever - and link
them in to one DLL. Is that so? If so, I guess there'd be some
ugliness regarding DllGetClassObject, and all the Dll... functions for
that matter. Or did you mean something else?

Quote:
>For the last question - you may be interested in the so called
>Browser Helper Objects (BHO) in IE 4 and above. Search on MSDN
>and you'll find some articles...

Sounds neat. It looks like some of the work I'll be doing will be
strictly IO, so I might be able to get into this.

Thanks Alexander!
 - Chris



Mon, 17 Nov 2003 13:05:38 GMT  
 (Slightly OT) General ActiveX information?

Quote:
>I guess then that what I care about are ActiveX controls. I assume
>this is a term with some meaning, inasmuch as browsers are going to
>download & maniuplate them in some defined away. Is there somewhere to
>learn about this?

The ways in which ActiveX controls are used is basically defined by the
standard OLE interfaces. Look at IViewObject, IOleObject, IOleInPlaceObject,
IOleClientSite, IOleInPlaceSiteWindowless etc.

Christian.



Mon, 17 Nov 2003 17:29:32 GMT  
 (Slightly OT) General ActiveX information?
See inline.

--
=====================================
Alexander Nickolov
Microsoft MVP [VC], MCSD

MVP VC FAQ: http://www.mvps.org/vcfaq
=====================================


Quote:
> >You won't find much about ActiveX because that is a fictitious term.
> >What it means is usually either ActiveX Controls or Automation.
> >(Some mean the COM DLLs produced by VB, BTW...) So don't bother
> >looking further...

> Hmmmmm. Always nice to know that a term doesn't really mean anything.
> I remember making the same discovery about Java Beans about 4 years
> ago - killing myself reading white papers & specs to answer the
> question "What IS a bean" - then determining that basically there's no
> such thing.

> I guess then that what I care about are ActiveX controls. I assume
> this is a term with some meaning, inasmuch as browsers are going to
> download & maniuplate them in some defined away. Is there somewhere to
> learn about this?

Virtually every ATL book on the market explains ATL's support for ActiveX
Controls (which is pretty decent BTW). If you are interested in knowing
the real technology behind though, they'll fall short. The literature on
the theory is very scarce. Read chapters 17-24 of "Inside OLE" and
chapters 2-3 of "ActiveX Controls Inside Out". "Inside OLE" is on MSDN
library, as for the other book - it's probably out of print too, so look
at used books stores (or online :) ). (Note, the second books is mostly
crap, but it does cover the technology quite decently in the two chapters
I mentioned...) "Inside OLE" describes mostly OLE embedded/linked
objects, but that is the root of ActiveX Controls (they are in-place
activated OLE objects) whose former name was OLE Controls. You have
to understand the concepts of hosting, siting, activation, persistence, etc
in order to understand ActiveX Controls...

Quote:

> >You can achieve code reuse on the source level as well - no need
> >to go binary. All you have to do is bundle all the top-level controls
> >in a single DLL (as MS did with the common controls for example).
> >Then the whole arsenal of C++ is at your disposal. I usually
> >recommend source code reuse over COM binary reuse.

> This sounds like a good idea that I would understand if I were better
> at this stuff. I *think* what you're saying is that I can go ahead and
> compile all my components - top level, low level, whatever - and link
> them in to one DLL. Is that so? If so, I guess there'd be some
> ugliness regarding DllGetClassObject, and all the Dll... functions for
> that matter. Or did you mean something else?

ATL is handling the object maintenance for you. You can have as many
ATL objects in a single project as you want... (on a second thought, may
be not _that_ many :)...)
Quote:

> >For the last question - you may be interested in the so called
> >Browser Helper Objects (BHO) in IE 4 and above. Search on MSDN
> >and you'll find some articles...

> Sounds neat. It looks like some of the work I'll be doing will be
> strictly IO, so I might be able to get into this.

> Thanks Alexander!
>  - Chris



Wed, 19 Nov 2003 00:55:00 GMT  
 
 [ 5 post ] 

 Relevant Pages 

1. slightly OT.

2. slightly OT: cross-platform binary compatibility?

3. Slightly OT: sorting

4. (slightly OT): Static Code Analysis Tool (C++)

5. C portability [slightly OT]

6. Slightly OT, but pertinant to ANSI C

7. slightly OT, but C# curious

8. Style Question (slightly O.T.)

9. Slightly OT: VC++6, Dikumware 3.08 and Stingray

10. Slightly OT - Class Hierarchy

11. slightly OT.... Joining mpeg files

 

 
Powered by phpBB® Forum Software