Wierd, how do I found out whether the user pressed okay or cancel?
this doesn't work, because it doesn't seem to return ****.
Code:int a = MessageBox(NULL,"Press ok or cancel","Mmmm",1);
Printable View
Wierd, how do I found out whether the user pressed okay or cancel?
this doesn't work, because it doesn't seem to return ****.
Code:int a = MessageBox(NULL,"Press ok or cancel","Mmmm",1);
Try
if(a==IDOK)
MessageBox(NULL,"OK","OK",0);
afterwards.
here are the values MessageBox() can return:
0 - Message Box could not be created.
IDABORT - Abort button was selected.
IDCANCEL - Cancel button was selected.
IDIGNORE - Ignore button was selected.
IDNO - No button was selected.
IDOK - OK button was selected.
IDRETRY - Retry button was selected.
IDYES - Yes button was selected
oh, okay thanks. Maybe this should go on the FAQ board?