dlbrown051198
asked on
CFileDialog::OnOK()
I have a problem with a subclassed dialog (derrived from CFileDialog) not closing when I call CFileDialog::OnOK().
After stepping through the code, it seems that the function uses some messages to know what exactly to do (pressing OK will not always close a FileDialog, it may just apply a filter to the filenames). What I'm curious about is, are there any messages I can post to "force" the dialog to close?? Calling CDialog::OnOK() closes the dialog but after doing that a few times Windows runs out of memory and can no longer display the common dialog boxes.
This is a 16-bit app.
After stepping through the code, it seems that the function uses some messages to know what exactly to do (pressing OK will not always close a FileDialog, it may just apply a filter to the filenames). What I'm curious about is, are there any messages I can post to "force" the dialog to close?? Calling CDialog::OnOK() closes the dialog but after doing that a few times Windows runs out of memory and can no longer display the common dialog boxes.
This is a 16-bit app.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Have you tried calling OnCancel instead.
ASKER