Click here to Skip to main content
15,887,585 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Format a CString value from longdate to shortdate Pin
Kalthoff22-Feb-06 23:45
Kalthoff22-Feb-06 23:45 
AnswerRe: Format a CString value from longdate to shortdate Pin
James R. Twine23-Feb-06 2:49
James R. Twine23-Feb-06 2:49 
Questioncreating folders with HTTPS Pin
logicaldna22-Feb-06 22:31
logicaldna22-Feb-06 22:31 
QuestionCHttpConnection for post method Pin
murali_utr22-Feb-06 22:29
murali_utr22-Feb-06 22:29 
QuestionHow to hook system's Drag&drop operation Pin
welli22-Feb-06 21:57
welli22-Feb-06 21:57 
QuestionCreate xml with 4 levels use dataset in .Net Pin
Koibito Yo22-Feb-06 21:21
Koibito Yo22-Feb-06 21:21 
AnswerRe: Create xml with 4 levels use dataset in .Net Pin
Ryan Binns22-Feb-06 21:28
Ryan Binns22-Feb-06 21:28 
Questioncleanly teminating an invisible dialog application; Pin
pc_dev22-Feb-06 21:10
pc_dev22-Feb-06 21:10 
I have used following technique to make dialog invisible
at startup; which i have taken from Nishant Sivakumar's
article "Some handy dialog box tricks, tips and
workarounds".


void CTest_deleteDlg::OnWindowPosChanging(WINDOWPOS FAR* lpwndpos)
{
if(!visible)
lpwndpos->flags &= ~SWP_SHOWWINDOW;

CDialog::OnWindowPosChanging(lpwndpos);
}

The problem is how can i terminate cleanly an invisible dialog application

I have tried following;

1. Sending postmessage(wm_close) to dialog but it
donot work; probably because the dialog is invisible.

2. OnOK() is also not working.

3. Showing the dialog and immediately and sending close message produces
a splash therefore avoided.

3. exit(1) works fine but I am not sure that it teminates
application cleanly or not so, I want to avoid this.

4. calling the Exit instance of main application even donot work!

((CMYApp*)AfxGetApp())->ExitInstance();

this should work because I am calling application object exit? but it wont?

I am looking for a clean solution to terminate a hidden dialog application.

Thanks in advance.Rose | [Rose]

AnswerRe: cleanly teminating an invisible dialog application; Pin
khan++22-Feb-06 21:26
khan++22-Feb-06 21:26 
AnswerRe: cleanly teminating an invisible dialog application; Pin
Ryan Binns22-Feb-06 21:27
Ryan Binns22-Feb-06 21:27 
AnswerRe: cleanly teminating an invisible dialog application; Pin
Vinaya22-Feb-06 21:30
Vinaya22-Feb-06 21:30 
AnswerRe: cleanly teminating an invisible dialog application; Pin
ThatsAlok22-Feb-06 23:09
ThatsAlok22-Feb-06 23:09 
GeneralRe: cleanly teminating an invisible dialog application; Pin
David Crow23-Feb-06 3:48
David Crow23-Feb-06 3:48 
QuestionHow can I get a pointer to CDC in a Form's paint method Pin
signbit22-Feb-06 20:52
signbit22-Feb-06 20:52 
AnswerRe: How can I get a pointer to CDC in a Form's paint method Pin
khan++22-Feb-06 21:30
khan++22-Feb-06 21:30 
Questionvideo capture Pin
marun8622-Feb-06 20:50
marun8622-Feb-06 20:50 
AnswerRe: video capture Pin
J512198224-Feb-06 0:02
J512198224-Feb-06 0:02 
Questiontabs on list box control Pin
picazo22-Feb-06 20:33
picazo22-Feb-06 20:33 
Questionchecking the validity of hex? Pin
namaskaaram22-Feb-06 19:23
namaskaaram22-Feb-06 19:23 
AnswerRe: checking the validity of hex? Pin
Ryan Binns22-Feb-06 19:39
Ryan Binns22-Feb-06 19:39 
GeneralRe: checking the validity of hex? Pin
Blake Miller23-Feb-06 4:44
Blake Miller23-Feb-06 4:44 
GeneralRe: checking the validity of hex? Pin
Ryan Binns23-Feb-06 18:06
Ryan Binns23-Feb-06 18:06 
GeneralRe: checking the validity of hex? Pin
Blake Miller24-Feb-06 4:27
Blake Miller24-Feb-06 4:27 
AnswerRe: checking the validity of hex? Pin
kakan22-Feb-06 19:40
professionalkakan22-Feb-06 19:40 
Questionlow level file functions? Pin
filthy mcnasty22-Feb-06 18:23
filthy mcnasty22-Feb-06 18:23 

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.