Copying Files

wiscokid

Board Regular
Joined
Aug 2, 2004
Messages
112
I have a number of files in a folder and want to copy them all to another folder on my network.

I was going to accomplich this by opening a workbook, and within the autoopen macro have the files copied.

Does anyone know an easy way to copy all of the files from a given directory to another directory?

Thanks in Advance

Paul
 

Excel Facts

Bring active cell back into view
Start at A1 and select to A9999 while writing a formula, you can't see A1 anymore. Press Ctrl+Backspace to bring active cell into view.

Norie

Well-known Member
Joined
Apr 28, 2004
Messages
76,318
Office Version
  1. 365
Platform
  1. Windows
Do you really need to use Excel?

Can't you just use Windows Explorer, select the files, copy them and then paste them?
 

Barry Katcher

Well-known Member
Joined
Feb 25, 2002
Messages
4,053
Assuming you have access to the other folder, why not just use Windows Explorier?
 

wiscokid

Board Regular
Joined
Aug 2, 2004
Messages
112
There are over 30 files in 5 differnt directories which will be placed into one directory. This has to be done daily. I wanted the person who will be updating the files to have to only open an excel sheet and the rest would be taken care of.
 

Norie

Well-known Member
Joined
Apr 28, 2004
Messages
76,318
Office Version
  1. 365
Platform
  1. Windows
If you really need to do this using Excel VBA then why not take a look at the FileCopy statement.

If you need more specific help then I think more information is required.
 

Forum statistics

Threads
1,147,688
Messages
5,742,626
Members
423,744
Latest member
bkirtland

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top