ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   VBA code to copy multiple Excel files from C drive to network driv (https://www.excelbanter.com/excel-programming/432840-vba-code-copy-multiple-excel-files-c-drive-network-driv.html)

Cam

VBA code to copy multiple Excel files from C drive to network driv
 
Hello,

I have several Excel files reside on my C drive (faster refresh) that I
refreshed the data/chart daily, then copy the files to a network drive
overdriving existing files.

Opening each Excel files (10 files) to refresh the data, then copy to a
network drive is very time consuming, can you please help automate the
process?
Something like refresh all files in a folder (c drive), then copy and paste
over existing files on the a network folder. THanks

Jen[_8_]

VBA code to copy multiple Excel files from C drive to networkdriv
 
How about something like this, in pseudo code:

1. get a list of filenames using FileSystemObject
2. open each file using Application.Workbooks.Open and .Save. This
should refresh the contents.
3. copy each file to the new folder using FileCopy utility.

HTH, Jenn



All times are GMT +1. The time now is 01:39 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com