I would like to register my program to handle the mailto
protocol.
I have seen these answers
- How to register custom program to handle mailto protocol on Windows
- Register Windows program with the mailto protocol programmatically
I tried adding a new key or modifying the existing key at this path:
HKEY_CURRENT_USER\Software\Microsoft\Windows\Shell\Associations\URLAssociations\MAILTO\Userchoice
.
Additionally, I added my program to to the HKCR
root, but that did not make my program appear in the select list.
Also, for testing purposes, I tried changing the classname value of the mailto key at this path:
HKEY_CURRENT_USER\SOFTWARE\Clients\StartMenuInternet\GoogleChrome\Capabilities\
to the classname of my program. This actually worked, but instead of hacking into Google Chrome, I’d rather add my own registry key.
URLAssociations
How can I add my program as a legitimate handler for the mailto
protocol?
Best Answer
Here is a sample mail client registration - To register with Default Programs / modern Default Apps. You can modify it accordingly, leaving out non-essential parts.
I've uploaded the same in this Pastebin link.
For official documentation, refer Default Programs Registration at MSDN. Although the docs state it's not valid for Windows 10, it certainly applies (and works perfectly) in Windows 10. The registration part hasn't changed a bit in Windows 10.
Also, see: Windows 10 program default settings - Microsoft Community