View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.misc
Jeff Jeff is offline
external usenet poster
 
Posts: 921
Default VBA - open folder

Hi,

I saw this code in a book - it allows you to choose a directory path.

With Application.FileDialog(msoFileDialogFolderPicker)
.InitialFileName = Application.DefaultFilePath & "\"
.Title = "Please select a location for the backup"
.Show
If .SelectedItems.Count = 0 Then
MsgBox "Canceled"
Else
MsgBox .SelectedItems(1)
End If
End With

Here is the problem - when I choose a directory I cannot see the files in
the directory - is there a way to change the code so that I can see the files?

Thanks for your help