Home > other >  CMFCEditBrowseCtrl - which control to use in the .rc file ? - MFC C
CMFCEditBrowseCtrl - which control to use in the .rc file ? - MFC C

Time:07-25

I am working on an MFC project with part of it requesting the user to choose a folder destination.

Right now, I have it implemented using a non-editable CEdit box whose value is set by the path chosen by the user, who chooses it by clicking a CButton button which calls the CFolderPickerDialog found enter image description here

In my RC file this control is defined like this:

CONTROL         "",IDC_MFCEDITBROWSE_LOCAL_BACKUP_FOLDER,"MfcEditBrowse",WS_BORDER | WS_TABSTOP | 0x80,18,173,327,14

And yes, I use it exactly for the purpose you described.

CodePudding user response:

The docs at CMFCEditBrowseCtrl say to use an EDIT control in the dialog resource then to use CMFCEditBrowseCtrl for the bound member.

All this would be easier to do with class wizard but can be accomplished manually as well.

  • Related