Click here to Skip to main content
15,917,709 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: ASSERT()! Why?And how to resolve it? Pin
KarstenK14-Jun-07 0:37
mveKarstenK14-Jun-07 0:37 
GeneralRe: ASSERT()! Why?And how to resolve it? Pin
kcynic14-Jun-07 1:20
kcynic14-Jun-07 1:20 
GeneralRe: ASSERT()! Why?And how to resolve it? Pin
KarstenK14-Jun-07 1:41
mveKarstenK14-Jun-07 1:41 
GeneralRe: ASSERT()! Why?And how to resolve it? Pin
kcynic14-Jun-07 2:11
kcynic14-Jun-07 2:11 
GeneralRe: ASSERT()! Why?And how to resolve it? Pin
KarstenK14-Jun-07 2:20
mveKarstenK14-Jun-07 2:20 
GeneralRe: ASSERT()! Why?And how to resolve it? Pin
kcynic14-Jun-07 3:07
kcynic14-Jun-07 3:07 
GeneralRe: ASSERT()! Why?And how to resolve it? Pin
KarstenK14-Jun-07 3:17
mveKarstenK14-Jun-07 3:17 
AnswerRe: ASSERT()! Why?And how to resolve it? Pin
Roger Stoltz14-Jun-07 1:04
Roger Stoltz14-Jun-07 1:04 
A few lines down from the position in wincore.cpp you refer to is a comment that says:
// Note: if either of the above asserts fire and you are
// writing a multithreaded application, it is likely that
// you have passed a C++ object from one thread to another
// and have used that object in a way that was not intended.
// (only simple inline wrapper functions should be used)
//
// In general, CWnd objects should be passed by HWND from
// one thread to another.  The receiving thread can wrap
// the HWND with a CWnd object by using CWnd::FromHandle.
//
// It is dangerous to pass C++ objects from one thread to
// another, unless the objects are designed to be used in
// such a manner.

You should read this article[^] the "Thread Maps" section in this article[^].
After you've read those articles you will know what to do and how to pass a MFC window object from one thread to another.


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

GeneralRe: ASSERT()! Why?And how to resolve it? Pin
kcynic14-Jun-07 1:17
kcynic14-Jun-07 1:17 
GeneralRe: ASSERT()! Why?And how to resolve it? Pin
Roger Stoltz14-Jun-07 1:32
Roger Stoltz14-Jun-07 1:32 
GeneralRe: ASSERT()! Why?And how to resolve it? Pin
kcynic14-Jun-07 2:08
kcynic14-Jun-07 2:08 
GeneralRe: ASSERT()! Why?And how to resolve it? Pin
Roger Stoltz14-Jun-07 3:45
Roger Stoltz14-Jun-07 3:45 
GeneralRe: ASSERT()! Why?And how to resolve it? Pin
kcynic14-Jun-07 19:35
kcynic14-Jun-07 19:35 
GeneralRe: ASSERT()! Why?And how to resolve it? Pin
kcynic14-Jun-07 19:54
kcynic14-Jun-07 19:54 
GeneralRe: ASSERT()! Why?And how to resolve it? Pin
Roger Stoltz15-Jun-07 0:15
Roger Stoltz15-Jun-07 0:15 
GeneralRe: ASSERT()! Why?And how to resolve it? Pin
kcynic15-Jun-07 0:44
kcynic15-Jun-07 0:44 
GeneralRe: ASSERT()! Why?And how to resolve it? Pin
Roger Stoltz15-Jun-07 1:35
Roger Stoltz15-Jun-07 1:35 
GeneralRe: ASSERT()! Why?And how to resolve it? Pin
kcynic14-Jun-07 20:32
kcynic14-Jun-07 20:32 
Questionpicture control Pin
tyagineha14-Jun-07 0:17
tyagineha14-Jun-07 0:17 
AnswerRe: picture control Pin
Mark Salsbery14-Jun-07 7:50
Mark Salsbery14-Jun-07 7:50 
GeneralRe: picture control Pin
Hamid_RT14-Jun-07 20:09
Hamid_RT14-Jun-07 20:09 
QuestionRe: picture control Pin
tyagineha14-Jun-07 20:17
tyagineha14-Jun-07 20:17 
AnswerRe: picture control Pin
Mark Salsbery15-Jun-07 5:37
Mark Salsbery15-Jun-07 5:37 
QuestionGetting TCP/UDP Tables with ProcessIDs before XP Pin
Akin Ocal13-Jun-07 23:17
Akin Ocal13-Jun-07 23:17 
QuestionDebugging in VC++ Pin
Raj Prathap13-Jun-07 23:08
Raj Prathap13-Jun-07 23:08 

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.