so
Nyarlatotep wrote:
CFileDialog dlg( TRUE, "jpg", NULL, OFN_OVERWRITEPROMPT|OFN_HIDEREADONLY|OFN_PATHMUSTEXIST|OFN_FILEMUSTEXIST, szFilter, this ); if( dlg.DoModal() != IDOK ) { return; }
does not cause a problem if cancel is pressed but does cause a problem if you press ok right? I suspect that the problem lies in the code beyond this call. Pressing cancel will cause a 'return' to execute, pressing ok will cause what ever code is after this to execute... CFileDialog dlg( TRUE, "jpg", NULL, OFN_OVERWRITEPROMPT|OFN_HIDEREADONLY|OFN_PATHMUSTEXIST|OFN_FILEMUSTEXIST, szFilter, this ); if( dlg.DoModal() != IDOK ) { return; } ...WHAT CODE IS HERE?
cje