stathisaska
New Member
- Joined
- May 1, 2014
- Messages
- 8
Dear all,
I want to import data from 215 workbooks formatted the same way.
I have created a summary workbook which contains all filenames in A1:A215
I have created a macro to open all which it is like this
It takes 8 seconds to open 10 workbooks. I tried more and more, but for 215 it stuck.
I am running an iMac with a fusion drive and those specifications:
Processor Name: Intel Core i5
Processor Speed: 3,2 GHz
Number of Processors: 1
Total Number of Cores: 4
L2 Cache (per Core): 256 KB
L3 Cache: 6 MB
Memory: 8 GB
The workbooks have a total of 35mb
My questions:
I want to import data from 215 workbooks formatted the same way.
I have created a summary workbook which contains all filenames in A1:A215
I have created a macro to open all which it is like this
Code:
Sub open_all()
Dim filenames(215) As String
Dim time1 As Date
Dim time2 As Date
time1 = Now
For i = 1 To 215
filenames(i) = "/Users/soldier/Library/Containers/com.microsoft.Excel/Data/files/" & Cells(i, 1).Value
Next
MsgBox ("Filenames copied")
Dim WB As Workbook
For i = 1 To 10
Set WB = Workbooks.Open(filenames(i))
Next
time2 = Now
msgbox(time2-time1)
End Sub
It takes 8 seconds to open 10 workbooks. I tried more and more, but for 215 it stuck.
I am running an iMac with a fusion drive and those specifications:
Processor Name: Intel Core i5
Processor Speed: 3,2 GHz
Number of Processors: 1
Total Number of Cores: 4
L2 Cache (per Core): 256 KB
L3 Cache: 6 MB
Memory: 8 GB
The workbooks have a total of 35mb
My questions:
- Do you believe this task it's not possible ?
- Can I import data without even opening workbooks
- Can i open workbooks and keep them hidden
- Shall I open workbooks 1 by 1: get the information I need, close the workbook and then proceed to next one
- Would you recommend any other method to get the outcome I need ?
Last edited: