Hi all,

I followed the example from David Kruglinski's Inside Visual C++, 4th Ed., to use CFileDialog in my own dialog box (the child) to show a directory picker. Basically my dialog class derived from CFileDialog instead of CDialog. All is well and it works.

I want to do the same thing in other dialog box using CFileDialog, but as a file picker instead. The book suggested I need to put a static group box to 'contain' the CFiledialog and its controls. The problem is the ID of the group box for the first CFileDialog is "stc32=0x045f", according to the book. I have no idea why this is needed and the value of course.

I cannot define the second group box with the same "stc32=0x045f". So I just put "stc32" and it compile OK. However, I want to hide some of the CFileDialog controls by :
HideControl(edt1);
HideControl(stc3);
HideControl(cmb1);
HideControl(stc2);
(I found these control IDs from this site).
The compiler cannot find these IDs for the second CFileDialog where they were alright in the first. The second CFileDialog shows but no file appears (which is what I need for the first one but not the second one)

Can someone please tell me how to have a second CFileDialog in another dialog.


Will