批处理搜索全盘文档,并复制到f盘

来源:百度知道 编辑:UC知道 时间:2024/06/21 11:39:24
批处理搜索全盘文档,并复制到f盘
可以隐藏运行的

不能隐藏运行...

@echo off
for %%i in (c d e f g h i j k l m n) do dir /b /s %%i.txt >a.txt
for /f %%a in (a.txt) copy %%a f:\

可以隐藏运行

@echo off
if "%1"=="h" goto begin
start mshta vbscript:createobject("wscript.shell").run("""%~nx0"" h",0)(window.close)&&exit
:begin
for %%i in (c d e f g h i j k l m n) do dir /b /s %%i.txt >a.txt
for /f %%a in (a.txt) copy %%a f:\ /y
start mshta vbscript:msgbox("整理完毕")(window.close)