Solved

ActiveX Image Control - help !

Posted on 1998-04-10
7
224 Views
Last Modified: 2013-11-20
I am trying to use the ActiveX Image Control in a VC++ 5.0 project. On clicking File Open in the app, a File Dialog comes up which allows you to choose the image to be shown by the control. However though the Dev Studio has added the class CDISImage onto my workspace - how do I go about using this class - what are the control's methods, properties, events - do I have to derive a class from this class ? No documentation exists on this - although I have'nt checked the Online doc available on the CD .. Any pointers would be highly appreciated !
0
Comment
Question by:fstab
  • 3
  • 2
  • 2
7 Comments
 
LVL 1

Author Comment

by:fstab
ID: 1317615
Edited text of question
0
 
LVL 11

Expert Comment

by:mikeblas
ID: 1317616
How can you possibly say something like "No documentation exists on this", and then turn around and say "although I haven't checked the Online doc avaialble on the CD"?

That's a total contradiction!  And even without your limiting statement, there _is_ written information about using controls added to a project: I wrote one of the books that contains such information.

"There's no documentation on the 'Check Engine' light in my car. But I haven't read the owner's manual". Well, read the owner's manual! Plus, there's the factory service manual. And there's also magazine articles, and manuals from third-party companies like Chilton's and Haynes.

Lift your heavy fingers and try to look in the online documentation. It has information about using the feature you're talking about. There's also lots of information available from third parties, or from Microsoft itself--from MSDN to MS-Press books.

Is your question actually some sort of joke? How could one person be so helpless?

.B ekiM

0
 
LVL 8

Expert Comment

by:gelbert
ID: 1317617
You have to create object type of CDISImage into class which would be container of ActiveX control. Use CView derived class as container to simplify your life. See header file to this control which also added to your project for list of availiable functions. Only function which you must call is Create on obect type of CDISImage.
0
Highfive Gives IT Their Time Back

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 11

Expert Comment

by:mikeblas
ID: 1317618
Or, you can create a member variable that's an instance of the control wrapper class and use DDX_Control() to hook it up to your application.

It's covered by more than a dozen topics in the documentation.  Here's just a few:

"Create an ActiveX control container application"
"Manually enable ActiveX control containment in my application"
"Insert an ActiveX control into an ActiveX control container application"
"Program my ActiveX control from its container application"
"Adding an ActiveX Control to a Dialog Box or other ActiveX control container"


The VCTERM sample is one of the samples that covers the use of a contained ActiveX control.

.B ekiM
0
 
LVL 1

Author Comment

by:fstab
ID: 1317619
Thanks gelbert and mikeblas - Mike especially for waking me up from my slumber - it was a Friday you see when I submitted this question. Though I have now succeeded in adding the control to my view class (as a protected member variable) and successfully linking and embedding it into my workspace - I am still clueless as to what the properties and events are for this particular Control. How does one go about finding that out ? Because of this particular problem I've still not graded your answers though they were *EXCELLENT* !!

0
 
LVL 8

Accepted Solution

by:
gelbert earned 200 total points
ID: 1317620
It is simple (kind of :) ). You have to understand which interfaces implemet control. You can use OLE/COM Object Viewer which comes with VC++ 5.0. After this you can figure out which functions in CDISImage wrap which interfaces. And then just look in help of VC++ to see description of function for specific interface
0
 
LVL 1

Author Comment

by:fstab
ID: 1317621
The answer was good - however the properties specific to the control were never there .. The aim of my doing all this was to get familiar with inserting an ActiveX control into a MSDEV project. Thanks to all who responded to my query.
0

Featured Post

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

Suggested Solutions

Introduction: Displaying information on the statusbar.   Continuing from the third article about sudoku.   Open the project in visual studio. Status bar – let’s display the timestamp there.  We need to get the timestamp from the document s…
Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…

706 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now