How to exit an application by hitting an exit button
-
I 've created a single document database application in VC++.The problem is that I can not make out how to make an "exit" button which when hit will close the application immediately(i.e,MainFrame will be closed).
use this api
PostQuitMessage(0);
orthis->SendMessage(WM_CLOSE,0,0);
"I Think this Will Help"
visit me at http://www.thisisalok.tk
-
use this api
PostQuitMessage(0);
orthis->SendMessage(WM_CLOSE,0,0);
"I Think this Will Help"
visit me at http://www.thisisalok.tk
...or....
exit(0)
SkyWalker -
I 've created a single document database application in VC++.The problem is that I can not make out how to make an "exit" button which when hit will close the application immediately(i.e,MainFrame will be closed).
AfxGetMainWnd()-> PostMessage ( WM_CLOSE )
That will gracefully exit the app just as if you clicked the[X]
button in the window caption. --Mike-- LINKS~! Ericahist | 1ClickPicGrabber | CP SearchBar v2.0.2 | C++ Forum FAQ | You Are Dumb Strange things are afoot at the U+004B U+20DD