Click here to Skip to main content
15,897,968 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: CxImage Class? Pin
Paresh Chitte23-Mar-08 23:53
Paresh Chitte23-Mar-08 23:53 
AnswerRe: CxImage Class? Pin
Hamid_RT1-Apr-08 2:15
Hamid_RT1-Apr-08 2:15 
Questionhow to authenticate the windows user Pin
vineeshV23-Mar-08 23:33
vineeshV23-Mar-08 23:33 
QuestionRe: how to authenticate the windows user Pin
David Crow24-Mar-08 4:06
David Crow24-Mar-08 4:06 
GeneralC++ COM STA model Pin
George_George23-Mar-08 23:11
George_George23-Mar-08 23:11 
GeneralRe: C++ COM STA model Pin
James R. Twine24-Mar-08 1:30
James R. Twine24-Mar-08 1:30 
GeneralRe: C++ COM STA model Pin
George_George24-Mar-08 2:09
George_George24-Mar-08 2:09 
GeneralRe: C++ COM STA model Pin
James R. Twine24-Mar-08 2:31
James R. Twine24-Mar-08 2:31 
   Yes, any call into the interface (method, property, etc.) are translated into a message and placed onto the queue (if the call crosses apartment - is crossing application boundaries).  Not sure if connection points work the same way (and I rarely used them because of undesirable side-effects).  When the message pump runs, the message is dispatched to the COM message handler which takes over handing of the call.

   The message pump is a standard windows message queue (which is why the hidden window is required).

   One correction for my above post: The message pump is run by the thread that created/owns the COM object - I remember this because I had worker threads using COM in STA that needed to run a PeekMessage/GetMessage loop for things to work.  This also means that while COM creates the hidden window, it is owned by the calling thread because threads have to pump messages for their own windows.

   Peace!

-=- James
Please rate this message - let me know if I helped or not!<hr></hr>If you think it costs a lot to do it right, just wait until you find out how much it costs to do it wrong!
Remember that Professional Driver on Closed Course does not mean your Dumb Ass on a Public Road!
See DeleteFXPFiles



GeneralRe: C++ COM STA model Pin
George_George24-Mar-08 2:51
George_George24-Mar-08 2:51 
GeneralRe: C++ COM STA model Pin
James R. Twine24-Mar-08 3:10
James R. Twine24-Mar-08 3:10 
GeneralRe: C++ COM STA model Pin
George_George24-Mar-08 4:35
George_George24-Mar-08 4:35 
GeneralRe: C++ COM STA model Pin
James R. Twine24-Mar-08 4:46
James R. Twine24-Mar-08 4:46 
GeneralRe: C++ COM STA model Pin
George_George24-Mar-08 19:19
George_George24-Mar-08 19:19 
GeneralRe: C++ COM STA model Pin
James R. Twine24-Mar-08 23:46
James R. Twine24-Mar-08 23:46 
GeneralRe: C++ COM STA model Pin
George_George25-Mar-08 4:24
George_George25-Mar-08 4:24 
GeneralRe: C++ COM STA model Pin
James R. Twine25-Mar-08 6:19
James R. Twine25-Mar-08 6:19 
GeneralRe: C++ COM STA model Pin
George_George25-Mar-08 20:15
George_George25-Mar-08 20:15 
GeneralRe: C++ COM STA model Pin
James R. Twine26-Mar-08 1:40
James R. Twine26-Mar-08 1:40 
GeneralRe: C++ COM STA model Pin
George_George26-Mar-08 1:51
George_George26-Mar-08 1:51 
GeneralRe: C++ COM STA model Pin
Nemanja Trifunovic24-Mar-08 8:00
Nemanja Trifunovic24-Mar-08 8:00 
GeneralRe: C++ COM STA model Pin
George_George24-Mar-08 18:51
George_George24-Mar-08 18:51 
Generalafxwin.h Pin
specialhaha23-Mar-08 22:22
specialhaha23-Mar-08 22:22 
QuestionRe: afxwin.h Pin
CPallini23-Mar-08 22:44
mveCPallini23-Mar-08 22:44 
GeneralRe: afxwin.h Pin
specialhaha23-Mar-08 22:46
specialhaha23-Mar-08 22:46 
GeneralRe: afxwin.h Pin
David Crow24-Mar-08 4:11
David Crow24-Mar-08 4:11 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.