I have a sheet that lists image file names in column A. I would like a macro to read each cell for the image file name e.g. images.jpg, copy it from c:\images1 to c:\images2. Thanks in advance!
I have a sheet that lists image file names in column A. I would like a macro to read each cell for the image file name e.g. images.jpg, copy it from c:\images1 to c:\images2. Thanks in advance!
Hello San75,
This worked in my tests. If your files don't start on row 1 in column "A", change the variable RowBeg to the starting row.
Please Login or Register to view this content.
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!)
Hi Leith Ross. Thanks for the code. I need a slight modification. The list is located in a workbook that has a sheet called images. The first row will have a header so it needs to start at row 2. In my test it did do a file copy however the file size of the file copied was zero bytes. I also need it to skip any files that are already in the images2 folder and overwrite files where if the source file is a difference size. Thanks again.
Got it to work. I had missed out the "\" after the directory.
It failes when an image file is not present. Can you please add a skip if not found code too?
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks