Adding or registering a file type so it can be associated with an application
You should be able to do the following
- Open File Explorer (right click Start -> File Explorer)
- Find the file you want to associate
- Right click the file and select Properties
- In this window click Opens With
- Select the program you want to open this file
Note that this dialog box tries to guess what program to use. Sometimes it's very wrong. I had to scroll down, select More Apps, and then scroll down again and click Look for another app on this PC before it gave me a file explorer to look for files.
If all else fails, you can try to resort to commandline manipulations:
- Open
cmd.exe
with administrator rights (right-click on the shortcut to get this option) - Type
ftype extfile="C:\Program Files (x86)\YourProgram.exe" "%1"
where you replace the path with the executable of the program you want to use to open by default this extension (make sure to keep the"%1"
, this will get replaced dynamically to point to the file you're double-clicking on) and optionally replaceextfile
with a name of your choice to describe the type of file you're trying to open. Then press Enter. - Finally, type
assoc .ext=extfile
where you replaceext
by the extension you are trying to associate andextfile
with the name you chose above, then press Enter.
After this, you should normally be able to open the files by double-clicking. The filetype icon will change on the next OS reboot or after reopening an explorer window.
If you have multiple file extensions for the same filetype (eg, .ext2
) that can be opened with the same program, then you can simply redo only the last step, eg: assoc .ext2=extfile
. In this case, both ext
and ext2
files will be opened with YourProgram.exe
by double-clicking.