复制文件夹并使用命令提示符重命名 [英] Copying a Folder and renaming it using command prompt

查看:130
本文介绍了复制文件夹并使用命令提示符重命名的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试复制文件夹并将其粘贴到复制文件夹的同一目录中.

I am trying to copy a folder and paste it in the same directory it was copied from.

例如

C:\ Test是由文件夹ACDM组成的主目录,我想在同一目录中复制ACDM并将新文件夹重命名为ACDM1,该文件夹将具有与ACDM相同的所有文件

C:\Test is the main directory which consists of a folder ACDM, I would like to copy ACDM in the same directory and rename the new folder to ACDM1 which will have all the same files as ACDM has

我想使用命令提示符来完成

I would like to do it using command prompt

我尝试了以下

C:> Xcopy C:\ Test C:\ Test \ ACDM1/E/U 无法执行循环复制 0个文件已复制

C:>Xcopy C:\Test C:\Test\ACDM1 /E /U Cannot perform a cyclic copy 0 File(s) copied

失败,不确定是否要向REN命令添加XCOPY命令.

which fails, not sure hoe to add REN command with XCOPY command.

需要尽快提供帮助,因为我想创建一个批处理文件,该文件将创建一个现有文件夹的副本并根据从文本文件中检索到的名称对其进行重命名.

Need help ASAP as i would want to create a batch file which will create a copy of an existing folder and rename it according to a name retrieved from a text file..

推荐答案

xcopy "C:\Test\ACDM\*.*" "C:\Test\ACDM1\" /s/h/e/k/f/c

这篇关于复制文件夹并使用命令提示符重命名的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆