Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Get all files from folder
I want to open all files in a folder but do not want to use input box. Is
there a way of using something like the open files window (which pops open if you click File - Open menu in excel)? |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Get all files from folder
Try tis code:
Dim Fname As Variant Fname = Application.GetOpenFilename("Excel Files (*.xls),*.xls", 3, "Select a File to Open" ,, True) If Not IsArray(Fname) Then MsgBox "No file was selected." Exit Sub End If For i = LBound(Fname) To UBound(Fname) msg = msg & Fname(i) & vbCrLf ' This can be removed Workbooks.Open Fname(i) Next i ...... ..... exit sub "linglc" wrote: I want to open all files in a folder but do not want to use input box. Is there a way of using something like the open files window (which pops open if you click File - Open menu in excel)? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Pulling pdf files from general folder to specific folder | Excel Discussion (Misc queries) | |||
Copying all files in a folder to new folder | Excel Discussion (Misc queries) | |||
how can I specific a folder with wildcard criteria and excel will import all the correct files in that folder? | Excel Discussion (Misc queries) | |||
how can I specific a folder with wildcard criteria and excel will import all the correct files in that folder? | Excel Programming | |||
How to copy 30 csv files from a folder to another folder | Excel Programming |