Click here to Skip to main content
15,903,388 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
See more:
I have to force message box to foreground as it is running background in multithreaded application. pls help me wit this.
Posted
Comments
Herman<T>.Instance 15-Sep-11 14:21pm    
invoke the messagebox?
Herman<T>.Instance 15-Sep-11 17:06pm    
hint: http://cboard.cprogramming.com/faq-board/27123-faq-how-do-simple-multi-threading-c-cplusplus-cplusplus.html
bunathangaraj 16-Sep-11 0:51am    
Yes ...

1 solution

have a good time

if you mean that you want to show a MessageBox in the foreground of the window, use it :
mabe help you

void a(){
HWND h=GetForegroundWindow();
MessageBox(h,_T("Hi"),0,0);
}

void CMyclass::OnButton1Click(){
a();

}
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900