Computer >> บทช่วยสอนคอมพิวเตอร์ >  >> ระบบ >> Windows

วิธีลบ File Type Associations ด้วย Registry Editor ใน Windows 11/10

ใน Windows 11 หรือ Windows 10 สามารถ Configure, Export, Import File Associations ตั้ง/เปลี่ยน file associations และ extensions ด้วย GUI ได้ แต่ไม่มีตัวเลือกลบ file type association ที่มีอยู่ ในบทความนี้จะแนะนำขั้นตอน ลบ File Type Associations ด้วย Registry Editor

วิธีลบ File Type Associations ด้วย Registry Editor ใน Windows 11/10

File Type Association คืออะไร?

พื้นฐานแล้ว file association ผูกไฟล์กับแอปพลิเคชันเฉพาะที่เปิดไฟล์นั้นได้ คล้ายกัน file type association ผูกประเภทไฟล์ (เช่น .docx) กับแอปที่ตรงกัน (Microsoft Word) นามสกุลไฟล์เดียวอาจมี association มากกว่าหนึ่งสำหรับการกระทำต่างๆ - แอปหนึ่งอาจผูกกับนามสกุลเพื่อเปิดไฟล์ แต่อีกแอปก็อาจผูกเพื่อเปิดและแก้ไข

ลบ File Type Associations ด้วย Registry Editor

การผูก file type กับโปรแกรมทำได้หลายทาง: ใช้ Open with dialog ติ๊ก Always use this app to open, หรือผ่าน Default Programs/Default Apps File type association ช่วยมาก แต่อาจเสียหาย ทำให้ไฟล์เปิดด้วยแอปอื่นที่ไม่เหมาะสม ในกรณีนี้ ให้ลบ file type associations ของไฟล์นั้น เพื่อไม่ให้เปิดด้วยแอปที่ผูกไว้โดยปริยาย

สำหรับบทความนี้ สมมติว่าคุณผูกไฟล์ .ผิดพลาด ชื่อ .bak สามารถ reset ทุก Apps และ File Associations เป็นค่าเริ่มต้นใน Windows 11/10 ได้ แต่หากต้องการลบ association แทน ให้ทำผ่าน registry ตามคำแนะนำด้านล่าง ในกรณีที่ทุกนามสกุลไฟล์เปลี่ยนเป็นรูปแบบไม่รู้จัก วิธีนี้ช่วยได้!

เนื่องจากเป็นการแก้ไข Registry แนะนำสำรอง Registry หรือสร้าง System Restore point ก่อน แล้วทำตามขั้นตอน:

  • กด Windows key + R เรียก Run dialog
  • พิมพ์ regedit กด Enter เปิด Registry Editor
  • ไปที่ registry key path:
HKEY_CLASSES_ROOT\.bak
  • ที่ตำแหน่งนั้น ด้านขวา ให้จดค่า (default) value data เป็น ProGID ที่ผูกกับ file type นั้น
  • คลิกขวา key .bak เลือก Delete
  • คลิก Yes ยืนยัน
  • ต่อไป ไปที่ HKEY_CURRENT_USER keys ด้านล่าง ลบ key .bak ด้วย
HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.bak
HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\Roaming\OpenWith\FileExts\.bak
  • ปิด Registry Editor
  • Restart PC

การตั้งค่า file association สำหรับ .bak ควรถูกลบแล้ว และไฟล์ที่ลบจะถูกตั้งเป็น unknown โดย Windows

นี่คือวิธีลบ File Type Associations ด้วย Registry Editor ใน Windows 11/10

บทความเกี่ยวข้อง: How to use Unassociate File Types remove File Type associations.

วิธีลบ default program จาก file type

เพื่อลบ default program จาก file type ใน Windows 11/10:

  • คลิก Start แล้ว Control Panel
  • คลิก Programs
  • คลิก Make a file type always open in a specific program ใต้ Default Programs
  • ใน Set Associations เลื่อนลงจนเจอนามสกุลที่ต้องการเปลี่ยน default program

วิธี reset default associations ใน Windows 10

เพื่อ reset ทุก Apps และ File Associations เป็นค่าเริ่มต้นใน Windows 11/10:

  • กด Win+I เปิด Windows Settings
  • ไป Apps > Default apps
  • เลื่อนลงล่างสุด
  • คลิก Reset
  • คลิก OK

File type associations เก็บไว้ใน Registry ที่ไหน?

File associations เก็บอยู่ใน HKLM\SOFTWARE\Classes และ HKCU\SOFTWARE\Classes ดู merged view ได้ที่ HKEY_CLASSES_ROOT hive เช่นกัน สามารถระบุแอปที่ผูกกับไฟล์ได้โดยคลิกขวาไฟล์ใน File Explorer แล้วคลิก Properties

วิธีลบ File Type Associations ด้วย Registry Editor ใน Windows 11/10