View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.misc
It's Me Again It's Me Again is offline
external usenet poster
 
Posts: 1
Default VBA project - OpenExcelFile

I would like this VBA - OpenExcelFile
to Open the Directory c:\files

where would I input a command to start open this folder ?

==============
Sub OpenExcelFile()
Dim vFile As Variant
'Showing Excel Open Dialog Form
vFile = Application.GetOpenFilename("Limit Scan File (*.xlx)," & _
"*.xlx", 1, "Select Excel File", "Open", False)
'If Cancel then exit
If TypeName(vFile) = "Boolean" Then
Exit Sub
End If
'Open selected file
Workbooks.Open vFile
End Sub
==============

Thanks...