Hi, this is my first post on this forum.
I would like to create a batch file to perform the following.
If a file within a specific directory is equal to today's date & ends with a specific extension then I want to copy the file.
The host directory is;
C:/tcp
The file extension is .raw
The target directory is
C:/poti
Is it possible to copy the file to the same file name?
I only want to perform the copy if the above two conditions are met. I am using ddmmyy.
Kind regards,
suprsnipes
Copy file with specific extension if it is equal to today
Moderator: DosItHelp
-
- Posts: 1
- Joined: 22 Dec 2011 20:29
-
- Expert
- Posts: 442
- Joined: 01 Aug 2010 17:13
- Location: Canadian Pacific
- Contact:
Re: Copy file with specific extension if it is equal to toda
I would help more, but please do some manual research. http://ss64.com/nt/xcopy.html
Type this into the console.
xcopy /?
What you're looking for is the /d switch, among others.
Type this into the console.
xcopy /?
What you're looking for is the /d switch, among others.