BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

OleObject

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi OLE Automation
View previous topic :: View next topic  
Author Message
Ron Wyman
Guest





PostPosted: Sat Jun 28, 2003 1:40 pm    Post subject: OleObject Reply with quote



When working with Kodak Imaging OCX components should I be using the
OLEObject property when getting, setting or calling methods? Why is this
variant exposed?

--
Ron Wyman
212-799-8281


Back to top
John Carlyle-Clarke
Guest





PostPosted: Tue Jul 01, 2003 8:59 am    Post subject: Re: OleObject Reply with quote



"Ron Wyman" <rswyman (AT) email (DOT) msn.com> wrote in
news:3efd9ab5$1 (AT) newsgroups (DOT) borland.com:

Quote:
When working with Kodak Imaging OCX components should I be using
the OLEObject property when getting, setting or calling methods?
Why is this variant exposed?


Since no-one has answered you, I'll have a shot although I could be
miles off! As far as I know, when dealing with ActiveX controls on
a form from a client point of view, what you are actually dealing
with is the Extender Object (in this case a TOleControl descendant).
This is the container for the ActiveX.

I use Delphi and VB, and to be honest I've only dealt with this
aspect of ActiveX using VB as the client. However, I would think it
mostly still applies...

The extender exposes all the properties and methods of the control's
main interface, as well as adding container properties like Name,
Width, Height etc. It does this using the auto-generated TLB code,
which builds a TOleControl descendant, and the import mechanism adds
all the methods and properties for the main dispatch interface for the
control. It creates little stub routines so that when you call a
method, it actually forwards it to the main interface of the control
it contains.

The extender provides the OleObject reference to get to the
contained ActiveX object (it's really an IDispatch that you get).

The only time I've ever needed to use this was when I gave all my
ActiveX controls a second interface, IVersionInfo. To get this
interface, I had to use this reference to get to the contained
object and QueryInterface for IVersionInfo. Doing the QI on the
extender of course did not work.

I can't really think of many other cases where you would need to use
this reference, although I am sure there are some.

I hope that helps a bit. I also hope that if I am talking complete
nonsense someone will correct me!

Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi OLE Automation All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.