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 / Languages / Managed C++ / June 2005

Tip: Looking for answers? Try searching our database.

Problems in Hosting an ActiveX Control in a WTL App

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
None - 18 Jun 2005 20:12 GMT
Hello

In order to host and use an ActiveX control (non-GUI) in a WTL app, I
followed the following steps:

1. During project creation, the ActiveX Hosting option is enabled.
2. In the dialog editor, the ActiveX control was inserted.
3. An event was added to the dialog by right clicking on the control
and selecting 'Events...'.
4. VS automatically created a .tlh file.
4. In order to use the control and its methods, the following code was
added:

void Connect()
{
   CComPtr<_DContinuumClient> m_Ctrl;
   hr = GetDlgControl(IDC_CONTINUUMCLIENTCTRL1,
       DIID__DContinuumClient,reinterpret_cast<void**>(&m_Ctrl));

   ATLASSERT(SUCCEEDED(hr));
}

_DContinuumClient is one of the dispinterfaces for the control. I can
see all the methods associated with this interface in the Typelib view
of the OLE Viewer. Unfortunately I can't access any of these methods in
the VC 6.0. 'm_Ctrl->' only shows the methods of the inherited IDispatch
interface such as AddRef and QueryInterface.

Can anyone tell me what I'm missing here? From the search of the
newsgroups and various websites, it seems that this should be all that
is needed.

Any help or hint is greatly appreicated.
None - 18 Jun 2005 21:25 GMT
I apologize as I posted this in the wrong newsgroup.

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.