Re: Emailing with default client



I've tried the mailto: method, but I can't seem to add an attachment. I'm watching another program do the very thing I am trying to do, but I don't know how it is doing it. It opens the default mail client compose window with the specified file attached. Amazingly it works when I have either Outlook Express or Thuderbird as my default mail client.

I've tried using the VB6 MAPI controls (MAPISession & MAPIMessages), I can sent through Outlook Express, but not Thunderbird. When I send through Outlook express it makes me enter my password twice - the fist time is when it connects (it then wants to download all my new messages), then again when I got to send. Frustrating :(

Cor Ligthert [MVP] wrote:
Carlos,

That is systemwebmail. A default client is opened in this way.
\\\
///a reference to System.Web
///using System.Web;
///using System.Diagnostic
Process.Start ("mailto:"; + HttpUtility.UrlEncode("NotMyFirstName@xxxxxxxxx")
+ "?subject=Does this helps" + "&body=How do you do?");
///

Cor

"Carlos J. Quintero [VB MVP]" <carlosq@xxxxxxxxxxxxxxxxxxx> schreef in bericht news:eAj7xD5YGHA.4424@xxxxxxxxxxxxxxxxxxxxxxx
Hi Dustin,

See if there is something here:

How do I send an email with attachments?
http://systemwebmail.com/faq/2.3.aspx

--

Best regards,

Carlos J. Quintero

MZ-Tools: Productivity add-ins for Visual Studio
You can code, design and document much faster:
http://www.mztools.com



"Dustin Davis" <dustin.davis@xxxxxxxxx> escribió en el mensaje news:OuMRB3yYGHA.4688@xxxxxxxxxxxxxxxxxxxxxxx
(using VB.NET 2005)

I'm writing a desktop application that I would like to have the ability to email files. I've set up the SMTP portion, now I would like to have a MAPI option.

I found a MAPI tutorial, but it does a bit more than I want it to. What I would like to do is this:

1. Open the default mail client's compose window.
2. Add an attachment

Then the user can fill out the To: Subject: etc.

Can anyone help me with this?

Thanks,
Dustin



.



Relevant Pages

  • Re: MAPIInitialize failed and get an error message
    ... If you can't change the config, then it's up to you to load Outlook's MAPI ... Make Microsoft Outlook your default mail client. ...
    (microsoft.public.win32.programmer.messaging)
  • Re: MAPIInitialize failed and get an error message
    ... You won't be able to rely on mapi32.lib and the MAPI stub library. ... Make Microsoft Outlook your default mail client. ...
    (microsoft.public.win32.programmer.messaging)
  • Re: Msgs are not going out automatically as desired with Outlook 2
    ... I tried creating a new user and profile (I removed all the xisting ... The app still cant Logon with simple mapi. ... > 3> set outlook as the default mail client ... > 4> configure outlook as the machines which works ...
    (microsoft.public.win32.programmer.messaging)
  • Re: How to extract outlook basic information by C++
    ... Extended MAPI is not a simple API, ... a dialog box popup and asked user to press ok for "logon" to outlook. ... mail client cannot fulfill the messaging requrest. ... thread-safe, but the usual threaded app restrictions apply. ...
    (microsoft.public.exchange.applications)
  • Re: How to replace an attachment from a file.wav to a winmail.dat
    ... And it will not have Outlook installed on. ... when the code tries to convert back from MAPI to MIME using the ... we created one stream object with the contents of the file using the ... and we created the new tnef stream using the OpenTnefStreamEx ...
    (microsoft.public.win32.programmer.messaging)