Windows XP Windows 7 Windows 2003 Windows Vista Windows 綜合教學 Linux 系統教學
Windows 10 Windows 8 Windows 2008 Windows NT Windows Server 電腦軟體教學
您现在的位置: Windows教程網 >> Windows教程 >  >> Windows 綜合教學 >> 關於 Windows

Windows 8 建立快速關機/重啟/鎖定/休眠捷徑:命令參數完整表與釘選技巧

編輯:關於 Windows

Windows 8 移除傳統開始選單,關機操作隱藏於 Charms 列 → 設定 → 電源,極不直覺。本文教學建立桌面捷徑一鍵執行關機、重啟、鎖定、休眠、睡眠,並釘選到開始畫面/工作列,附完整 shutdown.exe / rundll32.exe 參數表。

建立捷徑通用步驟

  1. 桌面空白處右鍵 →「新增」→「捷徑」。
  2. 「輸入項目位置」填入對應命令 →「下一步」→ 輸入名稱 →「完成」。
  3. 右鍵捷徑 →「內容」→「變更圖示」→ 選擇合適圖示 (如關機、重啟、鎖定圖示) → 確定。
  4. 右鍵捷徑 →「釘選到開始畫面」/「釘選到工作列」快速存取。

命令參數完整表

功能命令參數說明
關機shutdown.exe -s -t 0-s 關機、-t 0 等待 0 秒立即執行
定時關機 (30 秒)shutdown.exe -s -t 30-t 秒數
重新啟動shutdown.exe -r -t 0-r 重啟
鎖定工作站rundll32.exe user32.dll,LockWorkStation亦可用 Win+L
休眠rundll32.exe powrprof.dll,SetSuspendState寫入 hiberfil.sys 完全斷電
睡眠 (待命)rundll32.exe powrprof.dll,SetSuspendState 0,1,0參數 0,1,0 表待命模式
取消關機/重啟shutdown.exe -a-a 中止已排程關機
強制關閉應用程式關機shutdown.exe -s -f -t 0-f 強制關閉應用程式不提示

進階應用

  • 批次檔 (.bat) 整合多指令:如延遲 60 秒關機並顯示訊息 shutdown.exe -s -t 60 -c "系統將在 1 分鐘後關機進行維護"。
  • 工作排程器設定每日自動關機/重啟。
  • 捷徑圖示可從 %SystemRoot%\System32\shell32.dll、imageres.dll 擷取豐富系統圖示。

Windows 8.1/10 補充

Win8.1 Update 1 起在開始畫面右上角直接提供電源按鈕;Win10 開始選單內建電源選單。但捷徑方式仍適用於所有版本,且可自訂圖示、參數、釘選位置,彈性更高。

Copyright © Windows教程網 All Rights Reserved