How can i close my SDI Applcation?
-
Hello! I have tried to Close my SDI Apllication with Destroy(); or with OnClose(); but it didnt works! Does somebody know what function i have to use? Thanks a lot! Ronny
-
Try CMainFrame's PostMessage(WM_CLOSE) Happy Programming and God Bless! Internet::WWW::CodeProject::bneacetp
-
You might need to process the WM_CLOSE message.
void CMainFrame::OnClose() { CFrameWnd::OnClose(); return; }
-
You might need to process the WM_CLOSE message.
void CMainFrame::OnClose() { CFrameWnd::OnClose(); return; }
-
Hello! I have tried to Close my SDI Apllication with Destroy(); or with OnClose(); but it didnt works! Does somebody know what function i have to use? Thanks a lot! Ronny
-
Thanks that was a good idea, but i have forgotten to tell i need a function wich i can start in the View Class. I have tried to make a public function in Mainframe and use it in the View Class and it was complile able but it also didnt works...
-
Hello! I have tried to Close my SDI Apllication with Destroy(); or with OnClose(); but it didnt works! Does somebody know what function i have to use? Thanks a lot! Ronny
try using AfxGetMainWnd()->PostQuitMessage(0); :) good luck Imtiaz Qureshi
-
Thanks that was a good idea, but i have forgotten to tell i need a function wich i can start in the View Class. I have tried to make a public function in Mainframe and use it in the View Class and it was complile able but it also didnt works...
From CView: AfxGetMainWnd()->SendMessage(WM_CLOSE); or AfxGetMainWnd()->PostMessage(WM_CLOSE);
-
Hello! I have tried to Close my SDI Apllication with Destroy(); or with OnClose(); but it didnt works! Does somebody know what function i have to use? Thanks a lot! Ronny
AfxGetApp()->GetMainWnd()->PostMessage(WM_CLOSE); INTP
-
AfxGetApp()->GetMainWnd()->PostMessage(WM_CLOSE); INTP