Hi

Check this..

Steps: Enter source folder name, enter destination folder name.

Ensure you dont delete formula on from Cell C1 & D1.

First Click list file, this will list down all files with respective folder
name..

You can keep list intact, if Range size of col C & D is not same then you
can manually copy down formula, though macro is taking care of this part
also.

If you are fine with copying file you can run second Macro to copy files.


Cheers!!


On Mon, May 26, 2014 at 11:51 AM, Nasir Khan <nasirkhan.du...@gmail.com>wrote:

> Hello All,
>
> I have lots of folder in the path C:\Libraries\Documents\
>
> Viz: Folder A,  E, H, L, P etc
>
> Each folder has many workbooks where the workbook names has the folder
> Prefix
>
> Eg. Folder A will have many workbooks with name xxx-xxx-*A####*-xx
>      xxx-xxx-*A????-*xx and so on
>
>       Folder E will have workbooks with the name xxx-xxx-*Exxxx*-xx
>         xxx-xxx-*E????-*xx and so on
>
>       Folder H will have workbooks with the name xxx-xxx-*Hxxxx*-xx
>          xxx-xxx-*H????-*xx and so on
>
> There are many folders like this.
>
>
> In a separate Path viz C:\Myfolders\  I have all the folders eg *Axxxx*,
> *A????,* *Exxxx*, *E????,* *Hxxxx, H????* etc which are currently empty.
>
> I need a macro to run through the Path C:\Libraries\Documents\
>
> and copy the workbooks accordingly to the folder name found in the
> workbook name
>
> Eg: xxx-xxx-*Axxxx*-xx will be copied to Folder *Axxxx* and xxx-xxx-
> *A????*-xx to be copied to Folder *A????*
>
>      xxx-xxx-*Exxxx*-xx will be copied to Folder *Exxxx* and xxx-xxx-
> *E????*-xx to be copied to Folder *E????*
>
> and so on.
>
>
> Any help would be greatly appreciated as I do this manually now.
>
>
> TIA
>
>
> Nasir
>
> --
> Are you =EXP(E:RT) or =NOT(EXP(E:RT)) in Excel? And do you wanna be? It’s
> =TIME(2,DO:IT,N:OW) ! Join official Facebook page of this forum @
> https://www.facebook.com/discussexcel
>
> FORUM RULES
>
> 1) Use concise, accurate thread titles. Poor thread titles, like Please
> Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice
> will not get quick attention or may not be answered.
> 2) Don't post a question in the thread of another member.
> 3) Don't post questions regarding breaking or bypassing any security
> measure.
> 4) Acknowledge the responses you receive, good or bad.
> 5) Jobs posting is not allowed.
> 6) Sharing copyrighted material and their links is not allowed.
>
> NOTE : Don't ever post confidential data in a workbook. Forum owners and
> members are not responsible for any loss.
> ---
> You received this message because you are subscribed to the Google Groups
> "MS EXCEL AND VBA MACROS" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to excel-macros+unsubscr...@googlegroups.com.
> To post to this group, send email to excel-macros@googlegroups.com.
> Visit this group at http://groups.google.com/group/excel-macros.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
Are you =EXP(E:RT) or =NOT(EXP(E:RT)) in Excel? And do you wanna be? It’s 
=TIME(2,DO:IT,N:OW) ! Join official Facebook page of this forum @ 
https://www.facebook.com/discussexcel

FORUM RULES

1) Use concise, accurate thread titles. Poor thread titles, like Please Help, 
Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will not get 
quick attention or may not be answered.
2) Don't post a question in the thread of another member.
3) Don't post questions regarding breaking or bypassing any security measure.
4) Acknowledge the responses you receive, good or bad.
5) Jobs posting is not allowed.
6) Sharing copyrighted material and their links is not allowed.

NOTE  : Don't ever post confidential data in a workbook. Forum owners and 
members are not responsible for any loss.
--- 
You received this message because you are subscribed to the Google Groups "MS 
EXCEL AND VBA MACROS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to excel-macros+unsubscr...@googlegroups.com.
To post to this group, send email to excel-macros@googlegroups.com.
Visit this group at http://groups.google.com/group/excel-macros.
For more options, visit https://groups.google.com/d/optout.

Attachment: Copy file from Many folder to another-Backup.xlsm
Description: application/vnd.ms-excel.sheet.macroenabled.12

Reply via email to