Solved

MFC VC6++ ActiveX create (new)

Posted on 2000-04-10
2
351 Views
Last Modified: 2010-04-10
What I am trying to do, is: I am creating a custom ActiveX, with 2 main classes, CEMDELAXCtrl (control class of ActiveX) and my own dialog class CDlgEmb. Now, this class (the latter) generates (fires) an event at some point, and I need to transfer this 'firing' to the ActiveX control class (CEMDELAXCtrl), because I have named 2 events in this class, which will eventually be available to the user. How do I do it?
0
Comment
Question by:patrickz
2 Comments
 
LVL 3

Expert Comment

by:mnewton022700
ID: 2702696
Does your dialog have access to your control class. If so, you could simply call FireEvent on your control class.

If not, is your control the parent of your dialog? If so, you can get a pointer to it by casting GetParent().
0
 

Accepted Solution

by:
yuxiliu earned 50 total points
ID: 2720500
way 1.when you insert ACX to our project, wrapper class derived from CWnd, you just need to using:
DECLARE_MASSAGE_MAP() in class declaration
and
BEGINE_MESSAGE_MAP()
// put your message here
END_MESSAGE_MAP()
then call SendMessage or Posmessge to that control

way 2. put ON_MESSAGE(YOURMESSAGE, MESSAGEHANDLER) in when you write your activex Control
then send message to your control

0

Featured Post

Optimizing Cloud Backup for Low Bandwidth

With cloud storage prices going down a growing number of SMBs start to use it for backup storage. Unfortunately, business data volume rarely fits the average Internet speed. This article provides an overview of main Internet speed challenges and reveals backup best practices.

Question has a verified solution.

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

Introduction This article is a continuation of the C/C++ Visual Studio Express debugger series. Part 1 provided a quick start guide in using the debugger. Part 2 focused on additional topics in breakpoints. As your assignments become a little more …
Container Orchestration platforms empower organizations to scale their apps at an exceptional rate. This is the reason numerous innovation-driven companies are moving apps to an appropriated datacenter wide platform that empowers them to scale at a …
The goal of the video will be to teach the user the concept of local variables and scope. An example of a locally defined variable will be given as well as an explanation of what scope is in C++. The local variable and concept of scope will be relat…
The goal of the video will be to teach the user the difference and consequence of passing data by value vs passing data by reference in C++. An example of passing data by value as well as an example of passing data by reference will be be given. Bot…

773 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