A
A
Anton2014-12-02 11:46:12
cmd/bat
Anton, 2014-12-02 11:46:12

How to implement copying *.bat files?

It is necessary to copy 10 files from one folder to another (different names) so that after copying the first one, it is checked in this folder that it exists, and then the second one is copied.

Answer the question

In order to leave comments, you need to log in

4 answer(s)
A
Anton, 2014-12-02
@hunk3r

And to copy one file at a time, and not all in a crowd?)

S
sanchas, 2014-12-02
@sanchas

The question is not entirely clear. Is the list of files known in advance, or any 10 files, or are there only 10 files in a folder? How to understand

checked in this folder that it exists
? Do you admit that copying was unsuccessful, or is a strictly defined order of copying important to you?

A
Armenian Radio, 2014-12-02
@gbg

Use xcopy. Here is an example that copies all files from the dirA folder to the dirB folder

xcopy dirA/*.* dirB
if errorlevel 1 (
rem обработа ошибки
)
rem нет ошибки

Original answer

3
386DX, 2014-12-02
@386DX

copy /v
checking the correctness of copying files
, you can also check the check with the FC command
(file compare)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question