Click here to Skip to main content
16,005,222 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: issues with Vista / VS 2005? Pin
ldsdbomber30-May-07 17:05
ldsdbomber30-May-07 17:05 
GeneralRe: issues with Vista / VS 2005? Pin
ldsdbomber30-May-07 23:58
ldsdbomber30-May-07 23:58 
QuestionLinker : ERROR.....??? Pin
Thoyib Bustomi23-May-07 1:06
Thoyib Bustomi23-May-07 1:06 
AnswerRe: Linker : ERROR.....??? Pin
Rage23-May-07 1:23
professionalRage23-May-07 1:23 
GeneralRe: Linker : ERROR.....??? Pin
David Crow23-May-07 3:59
David Crow23-May-07 3:59 
QuestionRe: Linker : ERROR.....??? Pin
Hamid_RT23-May-07 1:31
Hamid_RT23-May-07 1:31 
AnswerRe: Linker : ERROR.....??? Pin
Naveen23-May-07 1:37
Naveen23-May-07 1:37 
QuestionOnActivateApp -> fails sometimes... Pin
Joan M23-May-07 0:42
professionalJoan M23-May-07 0:42 
Hello,

I'm using this code in all the dialogs of my app:

// Close the app automatically when it looses the focus. 
void CTAM_BODlg::OnActivateApp(BOOL bActive, DWORD dwThreadID)
{
	CDialog::OnActivateApp(bActive, dwThreadID);

	#ifndef DEBUG
		if (bActive == FALSE)
		{
			this->SendMessage(WM_CLOSE);
		}
	#endif
}


The thing is that it seems it don't work always, sometimes the application just don't get closed.

I cannot get the keyboard strokes and neither I can get the mouse events, the computer in which that application is installed is not a normal computer, it is a robot controller. The software on the robot allows me to launch my application, but it don't allow me to get the keystrokes as the keyboard is not a normal keyboard that they are handling in a special way. In any way, when the customer presses one defined key, automatically the robot controller computer sets the focus to the main robot application. After that point I'd like to get my application closed. And this is what it fails sometimes.

What could I check or modify in order to make it work always?

As always thank you in advance.
AnswerRe: OnActivateApp -> fails sometimes... Pin
Rage23-May-07 1:19
professionalRage23-May-07 1:19 
AnswerRe: OnActivateApp -> fails sometimes... Pin
Arman S.23-May-07 3:26
Arman S.23-May-07 3:26 
QuestionGlobalAddAtom function Pin
tom groezer23-May-07 0:41
tom groezer23-May-07 0:41 
AnswerRe: GlobalAddAtom function Pin
CPallini23-May-07 0:57
mveCPallini23-May-07 0:57 
QuestionPlease HELP!!! How do you create a dialog wizard inside a tab control?? [modified] Pin
dboogieman22-May-07 23:49
dboogieman22-May-07 23:49 
AnswerRe: Please HELP!!! How do you create a dialog wizard inside a tab control?? Pin
Joan M23-May-07 0:10
professionalJoan M23-May-07 0:10 
GeneralRe: Please HELP!!! How do you create a dialog wizard inside a tab control?? Pin
dboogieman23-May-07 0:37
dboogieman23-May-07 0:37 
GeneralRe: Please HELP!!! How do you create a dialog wizard inside a tab control?? Pin
Joan M23-May-07 0:45
professionalJoan M23-May-07 0:45 
QuestionHow to define each other class in self? Pin
hanlei000000000922-May-07 23:20
hanlei000000000922-May-07 23:20 
AnswerRe: How to define each other class in self? Pin
Sarath C22-May-07 23:49
Sarath C22-May-07 23:49 
QuestionKeep a DLL generated dialog on top Pin
fusion2344X22-May-07 22:57
fusion2344X22-May-07 22:57 
AnswerRe: Keep a DLL generated dialog on top Pin
Naveen23-May-07 1:41
Naveen23-May-07 1:41 
GeneralRe: Keep a DLL generated dialog on top Pin
fusion2344X23-May-07 5:18
fusion2344X23-May-07 5:18 
GeneralRe: Keep a DLL generated dialog on top [modified] Pin
Naveen23-May-07 14:10
Naveen23-May-07 14:10 
QuestionRe: Keep a DLL generated dialog on top Pin
David Crow23-May-07 4:04
David Crow23-May-07 4:04 
QuestionFolder Pin
josip cagalj22-May-07 21:34
josip cagalj22-May-07 21:34 
AnswerRe: Folder Pin
Hamid_RT22-May-07 21:58
Hamid_RT22-May-07 21:58 

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.