Getting no Events ! - IDispEventSimpleImpl , DispEventAdvise
Dmitry Save'd the day ! Thank you !
The Problem as follows:
First I made my Button like this:
//---------------------------
// Connect.cpp
//---------------------------
CComQIPtr Office::_CommandBarButton spCmdButton(spNewBar);
m_spButton = spCmdButton;
pHdl-DispEventAdvise((IDispatch*)m_spButton,&__uuidof( Office::_CommandBarButtonEvents));
//---------------------------
// Connect.h
//---------------------------
CComPtrOffice::_CommandBarButton m_spButton;
Now I make it like this:
//---------------------------
// Connect.cpp
//---------------------------
spCmdButton = spNewBar;
pHdl-DispEventAdvise((IDispatch*)spCmdButton,&__uuidof (Office::_CommandBarButtonEvents));
//---------------------------
// Connect.h
//---------------------------
CComPtrOffice::_CommandBarButton spCmdButton;
---------------------------------
Greetings, Dave
---------------------------------
|