18
Nov

Calling Mailto using JavaScript

2 Comments » Popularity: 4%

This is a code snippet showing how you may call the “mailto” to open your mail program.

Calling Mailto using JavaScript

View Demo: New Window
Calling mailto via Javascript:
private void SendEmail(string email, string subject, string body)
{
     Uri uri = new Uri(String.Format("mailto:{0}?subject={1}&body={2}", email, subject, body));
     System.Windows.Browser.HtmlPage.Window.Navigate(uri);
}
  • DZone
  • Digg
  • del.icio.us
  • StumbleUpon
  • Reddit

Related Posts

2 Responses to “Calling Mailto using JavaScript”

  1. mike says:

    thank. you. so. f.ing much

  2. FiscusMedia says:

    This technique opens an empty browser window before sending the mailto link to Outlook. Is there any way to disable the popup?

Leave a Reply