Click here to Skip to main content
15,922,894 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: need to convert .txt format file to .xls(excel) format Pin
Hamid_RT24-May-07 0:57
Hamid_RT24-May-07 0:57 
AnswerRe: need to convert .txt format file to .xls(excel) format Pin
David Crow24-May-07 4:16
David Crow24-May-07 4:16 
GeneralRe: need to convert .txt format file to .xls(excel) format Pin
artihcv30-May-07 23:07
artihcv30-May-07 23:07 
GeneralRe: need to convert .txt format file to .xls(excel) format Pin
David Crow31-May-07 2:39
David Crow31-May-07 2:39 
Questioncall event of Activex in thread procedure! Pin
hameduser23-May-07 21:06
hameduser23-May-07 21:06 
QuestionRe: call event of Activex in thread procedure! Pin
Roger Stoltz23-May-07 21:26
Roger Stoltz23-May-07 21:26 
AnswerRe: call event of Activex in thread procedure! Pin
hameduser25-May-07 22:01
hameduser25-May-07 22:01 
GeneralRe: call event of Activex in thread procedure! Pin
Roger Stoltz27-May-07 22:02
Roger Stoltz27-May-07 22:02 
Ok, I interpret this as you spawn a thread inside your ActiveX component and try to fire an event from there.

Your ActiveX is presumably running in an STA, Single Threaded Apartment.
An STA can only have one single thread running inside it, if you create another thread you have to set up another apartment. This is done by calling ::CoInitialize[Ex]() in the thread.
To be able to use the source interface you fire the events on you have to marshal that interface to the new apartment. Whenever you cross apartment boundaries with an interface you have to marshal the interface. This can be done with ::CoMarshalInterThreadInterfaceInStream() / ::CoGetInterfaceAndReleaseStream() or through the GIT (Global Interface Table).

Have a look at Lim Bio Liong's article serie startnig here[^] for more info.


"It's supposed to be hard, otherwise anybody could do it!" - selfquote
"High speed never compensates for wrong direction!" - unknown

QuestionI know that here is not the best place to ask that, but... Pin
Nelek23-May-07 20:52
protectorNelek23-May-07 20:52 
AnswerRe: I know that here is not the best place to ask that, but... Pin
Johpoke23-May-07 21:01
Johpoke23-May-07 21:01 
GeneralRe: I know that here is not the best place to ask that, but... Pin
Nelek23-May-07 21:21
protectorNelek23-May-07 21:21 
GeneralRe: I know that here is not the best place to ask that, but... Pin
Johpoke23-May-07 22:31
Johpoke23-May-07 22:31 
QuestionC# dll from MFC application... Pin
nzhuda23-May-07 20:47
nzhuda23-May-07 20:47 
AnswerRe: C# dll from MFC application... Pin
nzhuda24-May-07 15:22
nzhuda24-May-07 15:22 
GeneralRe: C# dll from MFC application... Pin
keancaptinh12-Apr-09 20:49
keancaptinh12-Apr-09 20:49 
QuestionMultilanguage Resource compilation options Pin
XtremDev23-May-07 20:47
XtremDev23-May-07 20:47 
AnswerRe: Multilanguage Resource compilation options Pin
Nelek23-May-07 20:56
protectorNelek23-May-07 20:56 
GeneralRe: Multilanguage Resource compilation options Pin
XtremDev23-May-07 21:21
XtremDev23-May-07 21:21 
GeneralRe: Multilanguage Resource compilation options Pin
Nelek23-May-07 21:26
protectorNelek23-May-07 21:26 
AnswerRe: Multilanguage Resource compilation options [modified] Pin
Naveen23-May-07 22:39
Naveen23-May-07 22:39 
GeneralRe: Multilanguage Resource compilation options Pin
tom groezer24-May-07 1:37
tom groezer24-May-07 1:37 
QuestionRun at .Net 2.0 (errors) Pin
Tal S.23-May-07 20:36
Tal S.23-May-07 20:36 
AnswerRe: Run at .Net 2.0 (errors) Pin
Hamid_RT24-May-07 0:50
Hamid_RT24-May-07 0:50 
GeneralRe: Run at .Net 2.0 (errors) Pin
Tal S.24-May-07 1:33
Tal S.24-May-07 1:33 
QuestionRe: Run at .Net 2.0 (errors) Pin
Hamid_RT24-May-07 10:53
Hamid_RT24-May-07 10:53 

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.