Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / Interop / June 2005

Tip: Looking for answers? Try searching our database.

ActiveX Control

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Dan - 09 Jun 2005 20:21 GMT
Good Day All,

I have a series of Active X user controls that I am going to be needing to
use in a .NET project. However, I am running into an issue with the Wrapper
that is generated for the controls. All of these controls expect that their
parent implements a give interface. That is how they talk back to the parent.
In VB6 syntaxt that controls check that their parent implements that
interface using

If TypeOf UserControl.Extender.Parent Is IControlInterface Then

The issue I am having is that this call always fails. I tried implementing
the interface in the Form hosting the control but that did not work. I then
generated a wrapper using AxImp and outputting the source code file. I then
modified the file to implement the interfaces. When .NET wraps the com dll
that contains the interface definitions it creates three entries so I tried
implementing all of them but it did not work. The class delcerations looked
like

public class AxucBillDisplay : System.Windows.Forms.AxHost,
SafariInterface.IControlInterface, SafariInterface._IControlInterface,
SafariInterface.__IControlInterface

I am at a loss as to how I get this to work. Is it possible to get the
wrapper to implement this interface or am going to have to look at a Managed
C++ solution to walk the line between the two worlds?

I hope this makes sense.

Thanks for the help!

Dan
Willy Denoyette [MVP] - 10 Jun 2005 16:41 GMT
Not sure I understand you correctly, but you should not expect an ActiveX
Control container to implement other than the standard interfaces, so I
guess that the "parent" that Implements IControlInterface is another Control
implemented in VB6, please correct me if I'm wrong.

Willy.

> Good Day All,
>
[quoted text clipped - 36 lines]
>
> Dan
Dan - 10 Jun 2005 19:21 GMT
Willy,

Thanks for your response.

In VB6 we had a form that implemented the IControlInterface. The ActiveX
controls were then loaded onto that form which would become an MDI child that
we displayed in a MDI parent. The series of controls were always loaded on an
instance of that form.

Dan

> Not sure I understand you correctly, but you should not expect an ActiveX
> Control container to implement other than the standard interfaces, so I
[quoted text clipped - 43 lines]
> >
> > Dan

Rate this thread:







Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.