+ Reply to Thread
Results 1 to 4 of 4

Copy data from files located in sub folders.

  1. #1
    Registered User
    Join Date
    06-07-2015
    Location
    United Kingdom
    MS-Off Ver
    2010
    Posts
    38

    Copy data from files located in sub folders.

    Please Login or Register  to view this content.
    I'm using the code above (from a different forum) to search folders and sub folders for xlsx files, and then display results on the workbook I run it from,

    However I cant get this to work, Is there any obvious mistakes I've made?

    There is no error message so I'm assuming its all running okay its just the fact I get no results.

    Thanks in advance!

    Andrew.

  2. #2
    Forum Guru karedog's Avatar
    Join Date
    10-03-2014
    Location
    Indonesia
    MS-Off Ver
    2003
    Posts
    2,971

    Re: Copy data from files located in sub folders.

    Hi,

    The code is working well here.

    The code is looking for all Excel files with .xlsx extension (this means, excluding .xls, .xlsm, .xlsb) in folder :
    "C:\Users\Admin\Documents\test"

    Then for every file it found, it copy from the activesheet (the sheet that appeared if you open the file manually) on cell C4, D4, E4.

    Please check :
    - Is the path is correct ? --> "C:\Users\Admin\Documents\test"
    - Is the extension is correct ? --> .xlsx
    - Is the value you looking for is located at the sheet that appeared when you open the file manually ?
    - Are the values you trying to retreive located at C4, D4, E4 ?


    Regards
    1. I care dog
    2. I am a loop maniac
    3. Forum rules link : Click here
    3.33. Don't forget to mark the thread as solved, this is important

  3. #3
    Registered User
    Join Date
    06-07-2015
    Location
    United Kingdom
    MS-Off Ver
    2010
    Posts
    38

    Re: Copy data from files located in sub folders.

    Yes it appears to work for me now also... after an hour of trouble shooting!

    I have no idea what the problem was but its working now!

    thanks for the reply all the same.

    andy.

  4. #4
    Forum Guru karedog's Avatar
    Join Date
    10-03-2014
    Location
    Indonesia
    MS-Off Ver
    2003
    Posts
    2,971

    Re: Copy data from files located in sub folders.

    You are welcome, glad to hear you have sorted it out.


    Regards

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Use Excel VBA to Copy multiple files from different source folders to different folders
    By mm1234mail in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-12-2014, 01:17 PM
  2. Replies: 0
    Last Post: 05-26-2014, 07:47 PM
  3. Replies: 1
    Last Post: 09-12-2013, 09:23 PM
  4. Create folders and move and copy files into that folders
    By vijaybharthi in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 12-31-2010, 04:01 AM
  5. Replies: 0
    Last Post: 08-04-2010, 10:51 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1