+ Reply to Thread
Results 1 to 2 of 2

Copy all files containing certain text from one folder to another

  1. #1
    Forum Contributor
    Join Date
    12-06-2012
    Location
    sacramento,calif
    MS-Off Ver
    Excel 2010
    Posts
    217

    Copy all files containing certain text from one folder to another

    This code works but only copies the first file that meets the partial file name criteria and then stops, how can I get it to find and copy all that meet criteria & "*" & range("A1")




    Please Login or Register  to view this content.

  2. #2
    Forum Expert
    Join Date
    01-23-2013
    Location
    USA
    MS-Off Ver
    Microsoft 365 aka Office 365
    Posts
    3,863

    Re: Copy all files containing certain text from one folder to another

    Hi JJGF,

    You probably need a loop similar to the following (non-working code excerpt):
    Please Login or Register  to view this content.
    For a working example(including downloadable file) see post #2 in the following thread: http://www.excelforum.com/excel-prog...in-folder.html

    Lewis

+ 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] VBA to copy files that contain certain text within filename from one folder to another
    By NeilM in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 03-27-2015, 06:28 AM
  2. [SOLVED] Copy files from one folder to another folder (path in textbox)
    By yoko21 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 06-24-2014, 02:45 AM
  3. Copy excel and text files from one folder to another folder...
    By annupojupradeep in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 02-26-2014, 06:34 AM
  4. [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
  5. excel macro to copy data from multi text files in a folder to a single work sheet
    By dil_se in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 10-16-2012, 08:10 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