Solved

ActiveX Image Control - help !

Posted on 1998-04-10
7
234 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 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
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
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

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction: Dynamic window placements and drawing on a form, simple usage of windows registry as a storage place for information. Continuing from the first article about sudoku.  There we have designed the application and put a lot of user int…
Introduction: Load and Save to file, Document-View interaction inside the SDI. Continuing from the second article about sudoku.   Open the project in visual studio. From the class view select CSudokuDoc and double click to open the header …
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.
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…

623 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