设为首页 | 收藏本页
登陆您的帐号 | 免费注册帐号
全部栏目 > 计算机 > 软件 > 人工智能
下一篇上一篇 首页图文展示(无图)

批处理,全盘搜索并拷贝文件至指定目录

发布人:hy58
发布日期:2015-06-06 10:10:05
刷新日期:2015-06-06 10:10:05
回复或评论:0
阅览:266
@echo off   
    SetLocal EnableDelayedExpansion   
    for /f "delims=" %%i in ('fsutil fsinfo drives^|find /v ""') do (   
    set var=%%i    
    set temp=!var:~-3!   
    set drive=!temp: =!   
    fsutil fsinfo drivetype !drive!|findstr "固定">nul && for /f "tokens=*" %%a in ('dir /s/a-d/b !drive!123.exe 2^>nul') do (   
    set/a a=a+1   
    set ar!a!=%%~dpa   
    echo.   
    echo   !a! %%~dpa   
    ))   
    echo.   
    echo.   
    echo.   
    set/p ch=请选择:    
    echo.   
    for %%o in (%ch%) do (copy 1.txt "!ar%%o!")   
    echo.   
    pause   
评论(0) 暂无回帖


打印 收藏 关闭窗口 下一篇上一篇