Windows XP Windows 7 Windows 2003 Windows Vista Windows 綜合教學 Linux 系統教學
Windows 10 Windows 8 Windows 2008 Windows NT Windows Server 電腦軟體教學

Win7 CMD 指令複製/刪除頑固資料夾:xcopy、del、rd/rmdir 完整參數教學

編輯:Windows 7 系統介紹

複製資料夾(含子目錄)

xcopy F:\file C:\file /E

/E:包含空子目錄。

刪除資料夾及所有內容

DEL /S /Q D:\123\*.*   &rem 先刪檔案
RD  /S /Q D:\123       &rem 再刪資料夾本身
  • /S:遞迴處理子目錄。
  • /Q:安靜模式,不逐一確認。

補充:RD/RMDIR 細節

  • RD 資料夾名 僅能刪除空資料夾。
  • 非空資料夾必須加 /S;加 /Q 可跳過確認提示。
  • RD /S /Q 路徑 一行指令完成「灰飛煙滅」。

CMD 指令對鎖定、權限不足、路徑過長等頑固資料夾極具穿透力,建議收藏備查。

Copyright © Windows教程網 All Rights Reserved