XL5 VBA Q: Multiple file selection dialog box?

XL5 VBA Q: Multiple file selection dialog box?

Post by Geoff Bohli » Fri, 27 Oct 1995 04:00:00



I am trying to design a dialog box which allows the user to select
(not open) a number of different files, transfering them from
a list of files in the current directory on the left side of the
dialog box to a list of selected files on the right side.  I also
want the dialog box to have controls to allow the user to
navigate the directory structure, updating the list of files in
the current directory whenever the current directory changes, so that
files from different subdirectories can be put into the list on the right.
I have designed a dialog box which does this sort-of, but it is
pretty clunky and is also strictly tied to Windows at the moment.
I would like to have something that is transportable to the
Mac and is also as much as possible like standard file open
dialog box you get using Application.GetOpenfilename() [or whatever
that function is named].  Is there a built-in multiple file
selection dialog box in Excel that I just haven't been able to
find?  If not, does anyone know where I could locate such a thing
(like in some book of VBA Tricks to Amuse and Amaze Your Friends
and Employers)?  Thanks a lot.
-----------------------------------------------------------------------------



Lawrence KS, 66047                       (913) 864-3965
-----------------------------------------------------------------------------
 
 
 

XL5 VBA Q: Multiple file selection dialog box?

Post by Geoff Bohli » Fri, 27 Oct 1995 04:00:00


I am trying to design a dialog box which allows the user to select
(not open) a number of different files, transfering them from
a list of files in the current directory on the left side of the
dialog box to a list of selected files on the right side.  I also
want the dialog box to have the controls to allow the user to
navigate the directory structure, updating the list of files in
the current directory whenever the current directory changes, so that
files from different subdirectories can be put into the list on the right.
I have
designed a dia
-----------------------------------------------------------------------------



Lawrence KS, 66047                       (913) 864-3965
-----------------------------------------------------------------------------

 
 
 

XL5 VBA Q: Multiple file selection dialog box?

Post by John Walkenba » Mon, 30 Oct 1995 03:00:00


: I am trying to design a dialog box which allows the user to select
: (not open) a number of different files, transfering them from
: a list of files in the current directory on the left side of the
: dialog box to a list of selected files on the right side.  I also
: want the dialog box to have controls to allow the user to
: navigate the directory structure, updating the list of files in
: the current directory whenever the current directory changes, so that
: files from different subdirectories can be put into the list on the right.
: I have designed a dialog box which does this sort-of, but it is
: pretty clunky and is also strictly tied to Windows at the moment.
: I would like to have something that is transportable to the
: Mac and is also as much as possible like standard file open
: dialog box you get using Application.GetOpenfilename() [or whatever
: that function is named].  Is there a built-in multiple file
: selection dialog box in Excel that I just haven't been able to
: find?  If not, does anyone know where I could locate such a thing
: (like in some book of VBA Tricks to Amuse and Amaze Your Friends
: and Employers)?  Thanks a lot.

Good new and bad news. First the good news. Excel 7 for Windows 95 has a
new feature that lets you select mutliple files in the GetOpenFilename
statement. The bad news is that it doesn't work with Excel 5. If you want
to implement such a feature in Excel 5 you'll need to use a call to the

how you would do such a thing on the Mac.

The Batch Print utility in my Power Utility Pak (2.0a version) does
exactly this. It detects which version of Excel is running, and calls
COMMDLG for Excel 5 or uses GetOpenFilename for Excel 7.

John Walkenbach

 
 
 

1. XL5/VBA: Validating dialog input box-by-box?

Is there a way to validate edit-box entries in a custom
dialog box on a box-by-box basis -- that is, when users
tab out of each box -- rather than when the users hit "OK"
to exit the dialog itself?

My dialog now launches a validation routine when users
hit "OK" to continue -- if the input's clean, it moves
along; if the input requires correction it reopens the
dialog and prompts for corrected entries.

I would much prefer to trap and notify as soon as users
hit TAB to move out of each edit box.  The validation
is tricky -- I can't use the built in validation features
for this, and I'm not sure that those trigger on TAB
either. . . .

Any pointers?

Thanks

John Streeter

2. File sharing load simulator?

3. Responding to XL5 Dialog Boxes using VBA

4. writing directly to /dev/ttyS#

5. using the selection from a multiple selection list box

6. does pc-pine support the "offline" model?

7. How can I make multiple selection using a list box or combo box in webAF2.0?

8. COMP.SYS.IBM.PC.RT: IBM RT - Hardware - Frequently Asked Questions

9. XL5/VBA: Restarting dialog causing runtime error 1004: show method fail?

10. XL5 VBA Password dialog hide?

11. Change Label Value in Dialog Box in XL5?

12. DIALOG BOX help needed--XL5