Any application can register to appear as an e-mail client on the Start menu.
E-mail settings are kept in two places. The registry key
describes the e-mail applications that are installed on the system, as well as the default e-mail application.
describes the e-mail client that will be launched when the user clicks the Email icon on the Start menu.
If the HKCU\Software\Clients\Mail key is blank or missing, then the value from HKLM is used to select the e-mail application that will appear on the Start menu.
Underneath [HKLM\Software\Clients\Mail] may be zero or more subkeys, one for each registered email application. For example, a hypothetical system might have:
Consider a hypothetical e-mail client called "Lit Mail" by Litware Inc. Litware Inc. decides that it's suitable to register this e-mail client under the internal name "LitMail". Again, the internal name is some unique string that is never shown to the user.
To install an e-mail client as the default, use this registry key:
The "LocalizedString" value is a REG_SZ that provides a path to an .exe or .dll file and a decimal integer. The decimal integer is the string resource ID within the DLL whose value is to be displayed to the user. This allows the same registration to be used for multiple languages. Each language would provide a different ResourceDLL.dll, and the dynamic loading of the string from the DLL would result in the correct string being displayed, depending on the language selected. Note that the string begins with an "at" sign (@).
After updating the registry keys, the application broadcasts the WM_SETTINGCHANGE message with wParam = 0 and lParam pointing to the null-terminated string "Software\Clients\Mail" to notify the operating system that the default client has changed.
For backward compatibility with applications that do not support localized strings, the name of the application in the installed language should also be set as the default value for the key.
Use the following registry key to indicate the icon to display if the user selects Lit Mail as the Start menu mail program:
Use the following registry key to specify a command line for the e-mail client to use if the user clicks the E-mail menu item and Lit Mail is the preferred Start menu e-mail program. It is also the command line that is run if the user selects Read e-mail from the Microsoft Internet Explorer Tools menu. Notice that because there is a space in the path, the .exe name must be enclosed in quotes.
(Default)=REG_SZ:"C:\Program Files\LitwareInc\LitMail.exe" -inbox
If (and only if) the user specifies Lit Mail to be the default Start menu e-mail application, the Lit Mail application may write its internal name to the following key:
If (and only if) the user specifies Lit Mail to be the system-wide default e-mail application, the Lit Mail application may write its internal name to the key specified below. Note that access to this key may be restricted. Applications should not assume that all users have permission to change the system-wide default e-mail application.
Registration as the default Start menu e-mail application is different from registration as the system default e-mail client or the registered mailto handler. The system default e-mail client is started when the user clicks Read e-mail from the Internet Explorer Tools menu. The registered mailto handler is launched when the user clicks an URL of the form mailto:email@example.com. The Start menu e-mail application is used when the user clicks the E-mail icon on the Start menu.
If there is no default Start menu e-mail application specified, then the E-mail icon on the Start menu will start the system default e-mail client.
This article does not cover registering as the default mailto protocol handler. Applications that want to register in such manner should continue to follow existing specifications on this subject. This section mainly repeats information provided elsewhere. The only addition to the existing behavior is the definition of the [HKCU\Software\Clients\Mail] registry key.
Post a Comment
Note: only a member of this blog may post a comment.