Using Windows Forms Controls as ActiveX controls

Using Windows Forms Controls as ActiveX controls

am 15.10.2007 11:36:00 von larsgregersen

Hi

I have created a couple of Windows Forms controls in C# either by
composition or by subclassing existing controls. I'm able to use these
controls as ActiveX controls by using "register for COM Interop". I then
access the control in a old application written in C++ (using VS 205). This
works fine!

What if I wish to use a standard control, e.g. TreeView, as an ActiveX
control? I can of course subclass the control, without changing the
behaviour, but surely there must exist an easier way?!?!

Are the Windows Forms Controls already exposed as standard AxtiveX controls?

Are there any tricks or examples on how to handle events?

Re: Using Windows Forms Controls as ActiveX controls

am 16.10.2007 06:00:53 von notmyfirstname

Lars,

Probably is this page giving you the answers on your question.

http://msdn.microsoft.com/msdnmag/issues/02/06/rich/default. aspx

Cor

Re: Using Windows Forms Controls as ActiveX controls

am 18.10.2007 11:01:00 von larsgregersen

"Cor Ligthert[MVP]" wrote:

> Lars,
>
> Probably is this page giving you the answers on your question.
>
> http://msdn.microsoft.com/msdnmag/issues/02/06/rich/default. aspx

No, it didn't answer my question, but it is still useful information to me.
Thanks!