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

Win7 修改開啟方式導致所有程式變成同一個?INF 檔一鍵還原檔案關聯

編輯:Win7 系統基礎知識

手滑將某個程式的「開啟方式」改成 QQ、記事本等錯誤程式,導致所有 .exe、.lnk 檔案雙擊都用同一個程式開啟,系統幾乎癱瘓。重裝系統太麻煩,其實一個 .inf 安裝資訊檔 就能完美還原。

還原步驟

  1. 新建文字文件,貼入以下內容:
[Version]
Signature="$Chicago$"
[DefaultInstall]
DelReg=DeleteMe
[DeleteMe]
HKCU,"Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.exe"
HKCU,"Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.lnk"
  1. 另存為任意檔名,副檔名改為 .inf(例如 fix_assoc.inf)。
  2. 右鍵點擊該 .inf 檔案,選擇「安裝」。
  3. 稍等片刻,系統提示完成,檔案關聯即恢復正常。

檔案關聯錯誤範例

開啟方式錯誤範例

原理:該 INF 檔刪除使用者登錄檔中 HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.exe 及 .lnk 兩個分支,強制系統重建預設關聯。同樣適用於 Windows XP / Vista。

Copyright © Windows教程網 All Rights Reserved