+ Reply to Thread
Results 1 to 8 of 8

Copy Files From One Folder and Paste into another Folder

  1. #1
    Registered User
    Join Date
    03-21-2010
    Location
    United States
    MS-Off Ver
    Excel 2003
    Posts
    90

    Copy Files From One Folder and Paste into another Folder

    Hello Everyone,

    I have no clue on how to code this. I can copy specific files from one folder to another by code. However, I have an Excel file with various source folder locations (column A), with the file names (column B), and the destination folder for the files to go (column C). I would like the code to loop through column A and copy that folder and paste it into the destination folder that's identified in that row in column C.


    Thanks!

  2. #2
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: Copy Files From One Folder and Paste into another Folder

    Hello jadown,

    Do you want to copy the folder's contents, files and subfolders, to the destination folder or do you want to copy the files in column "B" that go with the folder in column "A" to the folder in column "C"? A few examples would help.
    Sincerely,
    Leith Ross

    Remember To Do the Following....

    1. Use code tags. Place [CODE] before the first line of code and [/CODE] after the last line of code.
    2. Thank those who have helped you by clicking the Star below the post.
    3. Please mark your post [SOLVED] if it has been answered satisfactorily.


    Old Scottish Proverb...
    Luathaid gu deanamh maille! (Rushing causes delays!)

  3. #3
    Registered User
    Join Date
    03-21-2010
    Location
    United States
    MS-Off Ver
    Excel 2003
    Posts
    90

    Re: Copy Files From One Folder and Paste into another Folder

    I want to copy the contents of the source folders to the identified destination folder that's listed in column C.

    Thanks!

  4. #4
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: Copy Files From One Folder and Paste into another Folder

    Hello jadown,

    The macro should ignore column "B" and copy the source folder and all it's files and subfolders and their files to the destination folder in column "C". Is that correct?

  5. #5
    Registered User
    Join Date
    03-21-2010
    Location
    United States
    MS-Off Ver
    Excel 2003
    Posts
    90

    Re: Copy Files From One Folder and Paste into another Folder

    Correct. I just want to copy of the contents in the source folder.

  6. #6
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: Copy Files From One Folder and Paste into another Folder

    Hello jadown,

    This should work for you. The folders are assumed to start in cell "A1". Change this if needed.

    Please Login or Register  to view this content.

  7. #7
    Registered User
    Join Date
    03-21-2010
    Location
    United States
    MS-Off Ver
    Excel 2003
    Posts
    90

    Re: Copy Files From One Folder and Paste into another Folder

    It works!!! Thank you so much!

  8. #8
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: Copy Files From One Folder and Paste into another Folder

    Hello jadown,

    You're welcome.

+ 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. VBA Copy specific files listed in Excel from folder & subfolders to another folder - FSO
    By HelloFriends in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 05-03-2019, 02:55 PM
  2. Copy Files from One Folder to Another Folder based on a List In Excel
    By civram1982 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 03-21-2019, 06:34 AM
  3. Replies: 18
    Last Post: 02-18-2019, 07:42 AM
  4. [SOLVED] Find files in one folder and paste them to another folder
    By Grilleman in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 06-12-2016, 02:26 PM
  5. [SOLVED] Copy certain files from Source folder to Destination folder
    By rizmomin in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 06-16-2015, 08:56 PM
  6. Replies: 12
    Last Post: 03-09-2015, 05:52 PM
  7. [SOLVED] VBA Code open files in folder, copy text to workbook-Next time folder opened copy only new
    By Bikeman in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 01-02-2013, 07:59 PM

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