Click here to Skip to main content
15,909,332 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: SOS [about Genetic Algorithms] Pin
onetwone14-Jun-04 22:19
onetwone14-Jun-04 22:19 
Questionhow to get these Rect Area Pin
yingkou14-Jun-04 16:50
yingkou14-Jun-04 16:50 
AnswerRe: how to get these Rect Area Pin
Johan Rosengren14-Jun-04 20:53
Johan Rosengren14-Jun-04 20:53 
GeneralException handling - catch(...) Pin
Tom Archer14-Jun-04 16:40
Tom Archer14-Jun-04 16:40 
GeneralRe: Exception handling - catch(...) Pin
Johnny ²14-Jun-04 21:19
Johnny ²14-Jun-04 21:19 
GeneralRe: Exception handling - catch(...) Pin
V.14-Jun-04 21:45
professionalV.14-Jun-04 21:45 
GeneralRe: Exception handling - catch(...) Pin
toxcct14-Jun-04 22:11
toxcct14-Jun-04 22:11 
GeneralSending messages with ::PostMessage Pin
kfaday14-Jun-04 16:32
kfaday14-Jun-04 16:32 
Hi!
i'm used to sending messages from a view class (in mfc), so first i get the window

HWND *viewhandle = new HWND;
*viewhandle = GetSafeHwnd();


copy the viewhandle to a variable of the object, and in a function, when i want to send a message, i call:

::PostMessage(*viewhandle, WM_ONWHATEVER, 0, 0);


That works fine. Now, i want to send a message from a class to another, and there are no windows involved.

I want to do this: class AA includes class BB. And i want to use a function of class AA from class BB, but class BB doesn't see class AA. So i want to send a message

But now i can't use GetSafeHwnd. How could i do that?

thanks!
GeneralRe: Sending messages with ::PostMessage Pin
Vadim Tabakman14-Jun-04 16:38
Vadim Tabakman14-Jun-04 16:38 
GeneralRe: Sending messages with ::PostMessage Pin
kfaday14-Jun-04 17:19
kfaday14-Jun-04 17:19 
GeneralRe: Sending messages with ::PostMessage Pin
Vadim Tabakman14-Jun-04 17:42
Vadim Tabakman14-Jun-04 17:42 
GeneralRe: Sending messages with ::PostMessage Pin
V.14-Jun-04 21:47
professionalV.14-Jun-04 21:47 
GeneralRe: Sending messages with ::PostMessage Pin
kfaday15-Jun-04 8:13
kfaday15-Jun-04 8:13 
GeneralRe: Sending messages with ::PostMessage Pin
V.15-Jun-04 21:01
professionalV.15-Jun-04 21:01 
GeneralRe: Sending messages with ::PostMessage Pin
kfaday16-Jun-04 2:28
kfaday16-Jun-04 2:28 
GeneralChanging the Mouse cursor Pin
kfaday14-Jun-04 16:19
kfaday14-Jun-04 16:19 
GeneralRe: Changing the Mouse cursor Pin
Johan Rosengren14-Jun-04 20:57
Johan Rosengren14-Jun-04 20:57 
GeneralRe: Changing the Mouse cursor Pin
kfaday15-Jun-04 8:24
kfaday15-Jun-04 8:24 
GeneralVC++ MFC questions Pin
henry00114-Jun-04 15:57
henry00114-Jun-04 15:57 
GeneralRe: VC++ MFC questions Pin
myfapb14-Jun-04 20:17
myfapb14-Jun-04 20:17 
GeneralRe: VC++ MFC questions Pin
henry00115-Jun-04 5:36
henry00115-Jun-04 5:36 
GeneralRe: VC++ MFC questions Pin
toxcct14-Jun-04 22:17
toxcct14-Jun-04 22:17 
GeneralRe: VC++ MFC questions Pin
henry00115-Jun-04 5:06
henry00115-Jun-04 5:06 
GeneralRe: VC++ MFC questions Pin
toxcct15-Jun-04 5:08
toxcct15-Jun-04 5:08 
GeneralRe: VC++ MFC questions Pin
henry00115-Jun-04 5:18
henry00115-Jun-04 5:18 

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.