Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Function Pointer to an ActiveX FireEvent Function?

Status
Not open for further replies.

Karl Blessing

Programmer
Feb 25, 2000
2,936
US
Right now i am atmpting to fire an event from within an object in the control(as you know the new control is defined by the objects within it, not vice versa), but what i got going is, a CEvent is defined on topside(the somethingctrl.cpp) and the server object below it has a pointer to that Cevent, then the CEvent is triggered, and then a Thread above the control waiting for the event, post a custom message to the Control, which in turn fires the event(only prob is i get a Invalid page fault when it atempts to post a message i am moving all the codes into a project that doesnt use &quot;invisible at runtime&quot; in hope that this invisiblity is disableing it from using a hWnd). Tho i think it would be simple enough if ic an manage to make a function pointer to the ActiveX event function, cept<br>
you could do void(Class::*theptr)(parameters), only prob is that the server object under the control wouldnt know what &quot;class&quot; is.<br>
any ideas on this big brain twister, the point is, i want to fire an event from the threads under the control(handled by the member objects).<br>
if i made the top control loop waiting for the event, then i'd end up locking VB up when the VB programmers try to use it, i'd make them check for a variable, but they insist they want a raised event.<br>
<br>
-Kb244
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top