I'm trying to quit my app conditionally from a dialog box. Can anyone help me find out how? I tried WM_QUIT, but because the call comes from the dialog box, the parent window does not close.