move Files
Posted: 26 Apr 2008 17:32
I want a batch file to move files from different folders present in the same path.
For E.g. The folders containing xml files are as follows:
d:\output\XML\vgh_he_2006-03-14_12-a-2659-04
d:\output\XML\vgh_he_2006-03-14_11-ue-1426-04
d:\output\XML\vgh_he_2006-03-10_5-g-354-06
d:\output\XML\vg_weimar_2006-02-21_4-k-5500-04-we
etc.
Here there is a second condition where each folder has total of five different xml files which we can identify by their filename.
For E.g.
d:\output\XML\vgh_he_2006-03-14_12-a-2659-04 contains
1) vgh_he_2006-03-14_12-a-2659-04_vt.xml
2) vgh_he_2006-03-14_12-a-2659-04_jurion.xml
3) vgh_he_2006-03-14_12-a-2659-04_ls.xml
4) vgh_he_2006-03-14_12-a-2659-04_pm.xml
5) vgh_he_2006-03-14_12-a-2659-04_cas.xml
What i need is to create five types of folders namely
vt
cas
ls
pm
jurion
in d:\output\XML
move the xml files present in the folder
d:\output\XML\vgh_he_2006-03-14_12-a-2659-04 depending on their file name.
i.e.
vgh_he_2006-03-14_12-a-2659-04_vt.xml will move to vt
vgh_he_2006-03-14_12-a-2659-04_cas.xml will move to cas
vgh_he_2006-03-14_12-a-2659-04_jurion.xml will move to jurion
vgh_he_2006-03-14_12-a-2659-04_pm.xml will move to pm
vgh_he_2006-03-14_12-a-2659-04_ls.xml will move to ls
The same need to be repeated to all the folders present in d:\output\XML
I already asked about this in the past also but no Reply
This time hoping to get a reply
If what I explained is not able to understand let me know.
Regards
Prashob
For E.g. The folders containing xml files are as follows:
d:\output\XML\vgh_he_2006-03-14_12-a-2659-04
d:\output\XML\vgh_he_2006-03-14_11-ue-1426-04
d:\output\XML\vgh_he_2006-03-10_5-g-354-06
d:\output\XML\vg_weimar_2006-02-21_4-k-5500-04-we
etc.
Here there is a second condition where each folder has total of five different xml files which we can identify by their filename.
For E.g.
d:\output\XML\vgh_he_2006-03-14_12-a-2659-04 contains
1) vgh_he_2006-03-14_12-a-2659-04_vt.xml
2) vgh_he_2006-03-14_12-a-2659-04_jurion.xml
3) vgh_he_2006-03-14_12-a-2659-04_ls.xml
4) vgh_he_2006-03-14_12-a-2659-04_pm.xml
5) vgh_he_2006-03-14_12-a-2659-04_cas.xml
What i need is to create five types of folders namely
vt
cas
ls
pm
jurion
in d:\output\XML
move the xml files present in the folder
d:\output\XML\vgh_he_2006-03-14_12-a-2659-04 depending on their file name.
i.e.
vgh_he_2006-03-14_12-a-2659-04_vt.xml will move to vt
vgh_he_2006-03-14_12-a-2659-04_cas.xml will move to cas
vgh_he_2006-03-14_12-a-2659-04_jurion.xml will move to jurion
vgh_he_2006-03-14_12-a-2659-04_pm.xml will move to pm
vgh_he_2006-03-14_12-a-2659-04_ls.xml will move to ls
The same need to be repeated to all the folders present in d:\output\XML
I already asked about this in the past also but no Reply
This time hoping to get a reply
If what I explained is not able to understand let me know.
Regards
Prashob