File Open Dialog - Open button Enable&Disable 
Author Message
 File Open Dialog - Open button Enable&Disable

Hi All

In my MFC project, I am using Windows'  FileOpen dialog.
My requirement is that the "Open" button should be disabled when no files
are selected in the file open dialog,
and when a file iis selected, the "Open" button should become enabled.
How can I do this? Any help greatly appreciated!
thanks in advance

Sunil



Fri, 05 Mar 2004 21:44:22 GMT  
 File Open Dialog - Open button Enable&Disable

Quote:
> In my MFC project, I am using Windows'  FileOpen dialog.
> My requirement is that the "Open" button should be disabled when no files
> are selected in the file open dialog,
> and when a file iis selected, the "Open" button should become enabled.
> How can I do this?

I'd post again in an MFC group to find out what your option are.

At the level of the API you can call GetOpenFileName() and specify a hook
procedure. The hook procedure should (I've never tried) allow you to enable
and disable controls on the dialog. Read the docs for the description of the
OFNHookProcOldStyle() function that you'll have to develop. Note carefully
the restrictions and the distinction between old-style and Explorer style
hooks.

Regards,
Will



Sat, 06 Mar 2004 00:28:26 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. File Open Dialog - Open button Enable&Disable

2. File Open Dialog - Open button Enable&disable

3. Disabling editing of list box items in the file open dialog box

4. file open dialog when clicking on button

5. How to enable/disable Toolbar button in Dialog Based MFC application

6. enable/disable toolbar button using pCmdUI->Enable(TRUE/FALSE) doesnt work

7. Enabling/Disabling a dialog Button

8. Real Simple: Enabling/disabling buttons on Dialog boxes

9. can't open file: to many files open

10. Difference between MRU File Open and Regular File Open

11. HOW TO Filter Files Without File Extention in Open File Dialog Box

12. File extension filtering for the file dialog presented for file opening

 

 
Powered by phpBB® Forum Software