+ Reply to Thread
Results 1 to 5 of 5

Get data from files in a folder

  1. #1
    Registered User
    Join Date
    06-26-2011
    Location
    Dubai
    MS-Off Ver
    Excel 2007
    Posts
    22

    Get data from files in a folder

    Hi all,

    I have some reports to upload in a software. These reports are excel files saved in a folder. They have unique names and set format. Since these reports have to be in a different format to be uploaded I wanted to write a piece of code to get my work done in two stages:
    Stage 1: Go to all the files in the folder and copy the first worksheet onto a new sheet.
    Stage 2: Once all the sheets are in one master file, Copy paste certain columns from all reports in a new worksheet to prepare the format.

    I can manage Stage 2, how do i approach Stage 1? Thanks for your help.

    With regards,
    Vishal Gupta

  2. #2
    Forum Expert snb's Avatar
    Join Date
    05-09-2010
    Location
    VBA
    MS-Off Ver
    Redhat
    Posts
    5,649

    Re: Get data from files in a folder

    Please, have a look at this post.



  3. #3
    Forum Contributor
    Join Date
    01-29-2011
    Location
    Pakistan
    MS-Off Ver
    Excel 2013
    Posts
    256

    Smile Re: Get data from files in a folder

    Hi VishalGupta,

    Try the below code. Set the path you wished too ( MyPath = "D:\great" ' change to suit)

    Please Login or Register  to view this content.
    Thanks
    farrukh

  4. #4
    Registered User
    Join Date
    06-26-2011
    Location
    Dubai
    MS-Off Ver
    Excel 2007
    Posts
    22

    Re: Get data from files in a folder

    Thanks guys..I won't be able to implement the coding you have given this week but I am sure it will work fine. Thanks for your help again. Will mark the thread as solved when I have implemented your code.

  5. #5
    Forum Contributor
    Join Date
    01-29-2011
    Location
    Pakistan
    MS-Off Ver
    Excel 2013
    Posts
    256

    Re: Get data from files in a folder

    If you like any of my suggestions please click the reputation icon in the right upper corner.

    Mark a thread as 'solved' instructions


    Thanks
    farrukh

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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