Locate the file extension you want to change the default program for. If you're not sure what extension the file is using, open File Explorer to find the file and use the View > File name extensions option to show file extensions. I have an first-time-startup option in my node.js program, but in the first-startup I want the app to tell the operative system that etfm files will be opened with that program. – Alliator Mar 30 '17 at 15:34.
Windows operating system allows user to for most kind of file extension type via Control Panel’s “Set Associations” or “Set Default Programs” under “Default Programs” link, or Setting’s “Default Apps” in Windows 10 or newer. However, there is no option or way to reset or restore the default apps for file types or protocols association back to original default the is configured in factory pre-installed or freshly installed Windows OS.

List of programs available under “Set Default Programs” link, such as Internet Explorer, Microsoft Office Outlook, Windows Calendar, Windows Mail, Windows Media Player and Windows Photo Gallery has defined their own default supported file extensions, types and protocols; while in Windows 10, “Default Apps” lists several categories and their respective default applications. And, user can easily set a program as the default program to use to open all file types and protocols it can open. Even so, it may not be the default app that is configured in Windows operating system originally. Unless user remembers and knows the original default apps and file association, and change the default program for the kind of file type accordingly using the graphical user interface (GUI) in Control Panel, else here’s another workaround to restore and reset the file association to the default Windows version of default app or file association. • Click Start Menu, and then type regedit in the Start Search and press ENTER. • Navigate to the following registry branch: HKEY_CURRENT_USER Software Microsoft Windows CurrentVersion Explorer FileExts [ext] Replace the [exe] with the actual file extension that you want to restore its file type default app association to revert back to original Windows default. If you unsure, simply browse through all the sub-key under FileExts.
• Delete the sub-key named UserChoice. • Exit from Registry Editor. Windows will now use original file associations that comes built into system for the particular file extensions with “UserChoice” deleted.
However, the trick is not foolproof, especially if the other related system registry keys for the particular extension have been corrupted or broken. In such cases, it may be necessary to. The trick works on most Windows operating systems, especially Windows Vista and Windows 7. In Windows 8, Windows 8.1 and Windows 10, the registry key may lack necessary permissions for editing or deletion, hence you may need to before able to manipulate it. If you’re using Windows 10, and if you want to reset the default apps for email, map, music player, photo viewer, video player and web browser to original factory default, navigate to Settings -> Apps -> Default apps, and hit the Reset button to set the default apps for above categories of files back to Microsoft recommended defaults.