473,394 Members | 1,821 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Open Default Email Client with Attachment

Going on 3 days and I am wodnering if I am just not looking in the right
place. If anyone nows how to do this please please help me.

I am developing a Windows form application using VB.NET 2005. I have a PDF
file that I want to attach to the local default email client and display it
so that the user can enter the rest of the information. Like one would see
using the right-click Send To Mail Recipient.

I tried using MailTo. But the "Attach=" only works with Outlook.

Is there a way to access the Send To Mail Receipient via command line or
..NET apis?
Is there another way to do this??

THANKS!!!
Hanika
Sep 20 '06 #1
2 31945
Hanika,

The answer is simple, adding an attachment programmatically is almost only
possible with using Office Outlook and than using the interop or Mapi to
that

A default mailclient has no attachment (as well not without dotNet)

This question is asked in the dotNet newsgroups probably 1001 times.

Cor

"Hanika" <Ha****@discussions.microsoft.comschreef in bericht
news:1A**********************************@microsof t.com...
Going on 3 days and I am wodnering if I am just not looking in the right
place. If anyone nows how to do this please please help me.

I am developing a Windows form application using VB.NET 2005. I have a
PDF
file that I want to attach to the local default email client and display
it
so that the user can enter the rest of the information. Like one would
see
using the right-click Send To Mail Recipient.

I tried using MailTo. But the "Attach=" only works with Outlook.

Is there a way to access the Send To Mail Receipient via command line or
.NET apis?
Is there another way to do this??

THANKS!!!
Hanika

Sep 22 '06 #2
Hello Cor,

Thanks for your message. You are correct, this question has been asked 1001
times but has been answered by few. I found a great sample in code proyect
that I used to do this. My application can open the default mail client with
an attachment. I have tested using the there main windows defaults: Outlook,
Outlook Express and hotmail. I had to use MAPI and interop.

Here is the link to the C# project I used in case anyone is interested:
https://secure.codeproject.com/cs/in...mapidotnet.asp

I converted to VB.NET.

Hanika

"Cor Ligthert [MVP]" wrote:
Hanika,

The answer is simple, adding an attachment programmatically is almost only
possible with using Office Outlook and than using the interop or Mapi to
that

A default mailclient has no attachment (as well not without dotNet)

This question is asked in the dotNet newsgroups probably 1001 times.

Cor

"Hanika" <Ha****@discussions.microsoft.comschreef in bericht
news:1A**********************************@microsof t.com...
Going on 3 days and I am wodnering if I am just not looking in the right
place. If anyone nows how to do this please please help me.

I am developing a Windows form application using VB.NET 2005. I have a
PDF
file that I want to attach to the local default email client and display
it
so that the user can enter the rest of the information. Like one would
see
using the right-click Send To Mail Recipient.

I tried using MailTo. But the "Attach=" only works with Outlook.

Is there a way to access the Send To Mail Receipient via command line or
.NET apis?
Is there another way to do this??

THANKS!!!
Hanika


Sep 22 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Jack | last post by:
Hello, I have a web-based application, located on the Internet, and I'd like to use a command button like a hyperlink. Ideally, I'd like to have the users default mail client be initiated with...
2
by: MB2 | last post by:
Hi all, Is there a function in visual c++ to open default mail client and pass to it destination addr, subject, body an an attachement (like SendObject in VB). Thanks.
88
by: Mike | last post by:
Is there a way to determine what a user's default email client is? I read a post from 3 years ago that said no. I guess I'm hoping something has come along since then.
1
by: vijaygparikh | last post by:
HI i am writting a code for open default mail client and it works fine. i want to attach a file with the default mail client but file is not attached with "mailto:" option. If any one has idea...
3
by: Mateusz Rajca | last post by:
Hello! How do I open the default email client, and attach a file? Matt
5
by: Ben K | last post by:
I saw some posting some time ago regarding a "trick" to automatically pop up an email editor with attachment using the default mail client. It is basically using automation to do the following...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.