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

Win10 右鍵選單加入「記事本」與「用記事本開啟」:登錄兩處部署

編輯:Win10 系統應用技巧

將記事本加入桌面/資料夾背景右鍵選單 (新建記事本) 與所有檔案右鍵選單 (用記事本開啟),透過登錄部署,無需第三方工具。

一、桌面/資料夾背景右鍵加入「記事本」 (新建文字檔替代)

  1. Win+R → regedit。
  2. 瀏覽 HKEY_CLASSES_ROOT\Directory\Background\shell。
  3. 右鍵 shell → 新增金鑰「記事本」 → 右鍵「記事本」 → 新增金鑰「command」。
  4. 雙擊 command 預設值 → 數值資料 C:\Windows\System32\notepad.exe → 確定。
  5. 右鍵桌面空白處即見「記事本」選項,點擊開啟新記事本視窗。
登錄路徑shell
command金鑰
數值資料

二、所有檔案右鍵加入「用記事本開啟」

  1. HKEY_CLASSES_ROOT\*\shell (不存在則新增)。
  2. shell 下新增金鑰「notepad」 → 預設值改為「用記事本開啟」。
  3. notepad 下新增金鑰「command」 → 預設值 notepad.exe %1 (注意空格)。

快速部署:匯入 .reg 檔

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\*\shell\notepad]
@="用記事本開啟"

[HKEY_CLASSES_ROOT\*\shell\notepad\command]
@="notepad.exe %1"

另存為 add_notepad_context.reg → 雙擊匯入 → 確定。

移除方法

登錄編輯器刪除對應金鑰 (HKEY_CLASSES_ROOT\Directory\Background\shell\記事本、HKEY_CLASSES_ROOT\*\shell\notepad) 即可恢復原狀。

右鍵選單擴充是 Windows 進階使用者必備技能,記事本、VS Code、PowerShell、Terminal 皆可同理部署。

Copyright © Windows教程網 All Rights Reserved