471,119 Members | 1,409 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,119 software developers and data experts.

Using ActiveX Controls

Dan
hI have a series of ActiveX controls written in VB6 that I want to now use in
VB.NET. In the VB6 world I loaded these controls at runtime as needed. This
worked great as they all implemented a common interface.

I am having some issues now when I try to do the same things in VB.NET. The
controls will load, however, they fail on the following line of code

If TypeOf UserControl.Extender.Parent Is IControlInterface Then
In VB6, the controls were hosted on a Form that implemented the
IControlInterface. When they loaded they check to make sure that the control
hosting them implements that interface. I imported the library containing
that interface definition into VB.NET. I then created a class that inherited
from AxHost and it implements that interface. However, it seems that when the
CLR and the RCW do their thing, the fact that the control hosting the ActiveX
control implements this interface is lost.

Is there anyway that I can get the ActiveX control to realize that the .NET
control hosting it does implement the interface? Is there an attribute that I
should be using?

Thanks for the help!

Dan
Nov 21 '05 #1
0 944

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

7 posts views Thread by Jarod_24 | last post: by
4 posts views Thread by Wilfried Mestdagh | last post: by
reply views Thread by Christian Nein | last post: by
2 posts views Thread by =?Utf-8?B?bGFyc2dyZWdlcnNlbg==?= | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.