Click here to Skip to main content
11,929,924 members (61,480 online)
Click here to Skip to main content
Add your own
alternative version

Tagged as


3 bookmarked

Get Default Mail Client Name

, 8 Jun 2011 CPOL
Rate this:
Please Sign up or sign in to vote.
How to get the default mail client name.
Here is the code:
public string getDefaultMailClient()
      object mailClient = Registry.GetValue(
        @"HKEY_LOCAL_MACHINE\SOFTWARE\Clients\Mail", "", "none");
      return mailClient.ToString();
  catch (Exception exGetDefaultMailClient)
      return "Outlook Express";


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Gustavo Mena
Software Developer gmSoft
Argentina Argentina
VB 6.0 / MsAccess / SQL Server
PHP Developer / MySQL
C# / Progress RDBS

You may also be interested in...

Comments and Discussions

GeneralIn Alternate 1, hkey returns a string ¨mailto\shell\open\com... Pin
Salam Y. ELIAS21-Jun-11 9:20
memberSalam Y. ELIAS21-Jun-11 9:20 
GeneralReason for my vote of 3 Agreed with the others who have comm... Pin
EdMan19614-Jun-11 10:15
memberEdMan19614-Jun-11 10:15 
GeneralReason for my vote of 2 Nice short how to but needs to be dr... Pin
NetSecurity14-Jun-11 3:40
memberNetSecurity14-Jun-11 3:40 
GeneralAgree with nbgangsta. Update your code. Pin
thatraja10-Jun-11 18:01
mvpthatraja10-Jun-11 18:01 
GeneralBetter yet; just throw an exception. If it's unable to find ... Pin
JV99998-Jun-11 22:43
memberJV99998-Jun-11 22:43 
GeneralYou're returning Outlook Express if you're unsuccessful? Are... Pin
nbgangsta8-Jun-11 22:07
membernbgangsta8-Jun-11 22:07 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

| Advertise | Privacy | Terms of Use | Mobile
Web03 | 2.8.151126.1 | Last Updated 8 Jun 2011
Article Copyright 2011 by Gustavo Mena
Everything else Copyright © CodeProject, 1999-2015
Layout: fixed | fluid