[AccessD] ShellExecute to send short e-mail via non-MS email clients...

Stuart McLachlan stuart at lexacorp.com.pg
Thu Nov 3 15:38:48 CST 2005


On 3 Nov 2005 at 17:33, Shamil Salakhetdinov wrote:

> > Works with Eudora.
> > Works fine for me with Pegasus Mail.
> > Works for me with Groupwise as well.
> > Works for Outlook
> > Works for Outlook Express
> Thank you everybody!
> Obviously it works with any default e-mail client on MS Windows.
> 
> > How it works under MS Windows "hoods" is described here:
> > http://www.microsoft.com/mind/0199/cutting/cutting0199.asp
> 
> For me this means there is protocol all the e-mail clients follow.
> And under MS Windows mshtml.dll seems to be the program, which is calling
> default mail clients - the question is how it does that?
> 

You are using two things here.

1. The URI mailto.
See RFC2368


2. MAPI.
This it the  protocol used to call the email client under Windows.

In this case, you are using a part of Microsofts built in browser  
(mshtml.dll is part of IE) to convert a mailto: URI  to a  MAPI command.

Note that mailto: is a very simple protocol which only has a limited number 
of parameters and there are cautions about using some of these.

<quote>
 Note that some headers are inherently unsafe to include in a message
   generated from a URL. For example, headers such as "From:", "Bcc:",
   and so on, should never be interpreted from a URL. In general, the
   fewer headers interpreted from the URL, the less likely it is that a
   sending agent will create an unsafe message.  
</quote>

It's up to mshtml.dll which parameters it choses to pass through the MAPI

MAPI is much richer, there are lots of things you can do with your own 
direct MAPI calls from an application that you can't do with mailto: such 
as include attachments and automatically send the message with no user 
intervention

-- 
Stuart





More information about the AccessD mailing list