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

Win10 右鍵選單新增「記事本」與「用記事本開啟」:註冊表手動建立與 REG 檔匯入雙法

編輯:關於 Windows

將記事本加入桌面/資料夾右鍵選單,可大幅提升啟動/編輯效率。兩大場景:空白處右鍵新增「記事本」直接啟動;檔案右鍵新增「用記事本開啟」快速編輯任意檔案。本文提供註冊表手動建立步驟與即用型 REG 檔程式碼。

場景一:桌面/資料夾空白處右鍵 → 「記事本」啟動

  1. Win+R → regedit → 定位:HKEY_CLASSES_ROOT\Directory\Background\shell
  2. 右鍵 shell → 新增 → 項目 → 命名 記事本。
  3. 在 記事本 下新增子項目 command。
  4. 雙擊 command 下的 (預設) 字串值 → 數值資料:C:\Windows\System32\notepad.exe → 確定。
  5. 即時生效,無需重開機。

場景二:任意檔案右鍵 → 「用記事本開啟」

  1. 定位:HKEY_LOCAL_MACHINE\SOFTWARE\Classes\*\shell(無則新增)。
  2. 在 shell 下新增項目 notepad,修改 (預設) 值為 用記事本開啟。
  3. 在 notepad 下新增 command 子項目,修改 (預設) 值為 notepad %1(notepad 與 %1 間有一空格)。

即用型 REG 檔 (複製存為 AddNotepadToContextMenu.reg 雙擊匯入)

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\Directory\Background\shell\記事本]
@="記事本"

[HKEY_CLASSES_ROOT\Directory\Background\shell\記事本\command]
@="C:\\Windows\\System32\\notepad.exe"

[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\*\shell\notepad]
@="用記事本開啟"

[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\*\shell\notepad\command]
@="notepad %1"

移除方式

註冊表編輯器中刪除對應項目:HKEY_CLASSES_ROOT\Directory\Background\shell\記事本 及 HKEY_LOCAL_MACHINE\SOFTWARE\Classes\*\shell\notepad,即時生效。

Win10 開啟記事本其他高效法

  • Win+R → notepad
  • Win+Q/S 搜尋「記事本」
  • 開始選單 → 「所有應用」→ 「Windows 附屬應用程式」→ 「記事本」
  • 任務列釘選記事本捷徑

右鍵選單整合最符合肌肉記憶,建議依習慣部署上述一或兩項。

Copyright © Windows教程網 All Rights Reserved