Read data from closed sheets into new spreadsheet.

Lynton

New Member
Joined
Mar 13, 2011
Messages
12
I have over 900 individual invoices created by excel, all are stored in a directory d:\invoices and are named Inv10001.xlsx to inv100909.xlsx
I have a new spreadsheet called Address Book with one sheet called Address list.

I want a macro or a vba code to open each of the invoice files and copy the addresses within the files to the address list sheet, then close the invoice file. this needs to happen to all the invoices.

I want to copy the field data from

Inv(files) Address list
A13 - A1
A14 - B1
A15 - C1
A16 - D1
A17 - E1
A18 - F1
A19 - G1
A20 - H1

Hopefully this should give me all the addresses from all of the invoices in new sheet.
any help appreciated.
 
Last edited:

Yongle

Well-known Member
Joined
Mar 11, 2015
Messages
4,664
Office Version
365
Platform
Windows
Are there any non-invoice files in that folder ? ( Is it safe to treat every file the same or does VBA need to check that name begins Inv...)
One of the 2 invoice numbers quoted in your post is not correct
 
Last edited:

Lynton

New Member
Joined
Mar 13, 2011
Messages
12
thanks for the reply'
invoices number from inv100001 to inv100909, only invoice files in that folder.
 

Forum statistics

Threads
1,081,992
Messages
5,362,601
Members
400,683
Latest member
LogChief

Some videos you may like

This Week's Hot Topics

  • populate from drop list with multiple tables
    Hi All, i have a drop list that displays data, what i want is when i select one of those from the list to populate text from different tables on...
  • Find list of words from sheet2 in sheet1 before a comma and extract text vba
    Hi Friends, Trying to find the solution on my task. But did not find suitable one to the need. Here is my query and sample file with details...
  • Dynamic Formula entry - VBA code sought
    Hello, really hope one of you experts can help with this - i've spent hours on this and getting no-where. .I have a set of data (more rows than...
  • Listbox Header
    Have a named range called "AccidentsHeader" Within my code I have: [CODE]Private Sub CommandButton1_Click() ListBox1.RowSource =...
  • Complex Heat Map using conditional formatting
    Good day excel world. I have a concern. Below link have a list of countries that carries each country unique data. [URL...
  • Conditional formatting
    Hi good morning, hope you can help me please, I have cells P4:P54 and if this cell is equal to 1 then i want row O to say "Fully Utilised" and to...
Top