+ Reply to Thread
Results 1 to 4 of 4

VBA to copy the contents of the sheet in a template file to all of the files in a folder

  1. #1
    Registered User
    Join Date
    11-12-2014
    Location
    Newcastle, England
    MS-Off Ver
    2010
    Posts
    54

    VBA to copy the contents of the sheet in a template file to all of the files in a folder

    Hopefully a nice little easy one for someone...

    I'm after VBA to copy the contents of the sheet in a template file into all of the files in a folder.

    The template will be getting updated every month (extra rows) and the sheet name will already exist in the individual files within the folder so maybe better to copy the contents rather than the sheet??

    Thanks in advance...

  2. #2
    Valued Forum Contributor
    Join Date
    12-01-2011
    Location
    Philippines
    MS-Off Ver
    Excel 2016
    Posts
    949

    Re: VBA to copy the contents of the sheet in a template file to all of the files in a fold

    try

    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    11-12-2014
    Location
    Newcastle, England
    MS-Off Ver
    2010
    Posts
    54

    Re: VBA to copy the contents of the sheet in a template file to all of the files in a fold

    Thanks very much k1dr0ck, that works really well.

    As the file location could be on a network/cloud etc, I've tried to make a tweak to it for the filepath

    sPathName = Application.ActiveWorkbook.Path

    It runs but it doesn't update do what I want it to do (but your c:\ etc path does).

    Can you please correct the error of my ways.

    Many Thanks,

  4. #4
    Valued Forum Contributor
    Join Date
    12-01-2011
    Location
    Philippines
    MS-Off Ver
    Excel 2016
    Posts
    949

    Re: VBA to copy the contents of the sheet in a template file to all of the files in a fold

    haven't had experience working with network or cloud drive
    try

    Please Login or Register  to view this content.

+ 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. [SOLVED] Renaming Multiple .Txt Files in a Folder to Specific Contents of First Line of Each File
    By bruppert in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 07-02-2019, 05:36 PM
  2. Replies: 18
    Last Post: 02-18-2019, 07:42 AM
  3. open folder and copy all contents into word file
    By is2_egypt in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-30-2015, 11:05 AM
  4. Replies: 2
    Last Post: 02-08-2014, 04:45 AM
  5. Copy Files from one folder to different folders based on pdf file name
    By jtammyg in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 01-23-2014, 11:49 AM
  6. Replies: 1
    Last Post: 03-28-2013, 02:49 PM
  7. Copy a Template workbook ans paste in a multiple Files in a Folder
    By arvind1979_3 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 03-24-2013, 09:07 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