473,624 Members | 2,150 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

sending emails using C++.Net

Hey there - hopefully last newbie question i will ask for a while!
I want my application to work where you click a button - and it either:
a) open a email application - insert the correct email address and add
a subject + any attachments
or
b) just create an email and send it off with appropriate attachments
etc.
However i have a snag - i have no idea what their smtp server will be
(and the chances are, neither will they!)

i found out about mailMessage and the SmtpMail - however to send the
email i need to know the smtp.

Is there anyway of finding out from their machine what their Smtp
details are? or anyway of opening up their default mail service and
slotting in these details? I found brief glimpses about using Shell -
but not too sure about whats going on there. Better yet would be some
book or some website that gives a bit more clear idea about all of
this.

Thanks in advance!

Nov 20 '06 #1
3 1544
You can use Simple MAPI to do this. This will use whatever Email client the
user has configured and will use it to actually send the message.

"lizii" wrote:
Hey there - hopefully last newbie question i will ask for a while!
I want my application to work where you click a button - and it either:
a) open a email application - insert the correct email address and add
a subject + any attachments
or
b) just create an email and send it off with appropriate attachments
etc.
However i have a snag - i have no idea what their smtp server will be
(and the chances are, neither will they!)

i found out about mailMessage and the SmtpMail - however to send the
email i need to know the smtp.

Is there anyway of finding out from their machine what their Smtp
details are? or anyway of opening up their default mail service and
slotting in these details? I found brief glimpses about using Shell -
but not too sure about whats going on there. Better yet would be some
book or some website that gives a bit more clear idea about all of
this.

Thanks in advance!

Nov 20 '06 #2

"lizii" <cr*****@gmail. comwrote in message
news:11******** **************@ j44g2000cwa.goo glegroups.com.. .
Hey there - hopefully last newbie question i will ask for a while!
I want my application to work where you click a button - and it either:
a) open a email application - insert the correct email address and add
a subject + any attachments
or
b) just create an email and send it off with appropriate attachments
etc.
Can anyone say "abusable for spam"?
>

However i have a snag - i have no idea what their smtp server will be
(and the chances are, neither will they!)

i found out about mailMessage and the SmtpMail - however to send the
email i need to know the smtp.

Is there anyway of finding out from their machine what their Smtp
details are? or anyway of opening up their default mail service and
slotting in these details? I found brief glimpses about using Shell -
but not too sure about whats going on there. Better yet would be some
book or some website that gives a bit more clear idea about all of
this.

Thanks in advance!

Nov 20 '06 #3
Thats a good point actually - i never thought of it that way.

We are actually using it within my company for a Fault and incident
report - plus to be used by our customers. So obviously i don't want
them to have the hassle of opening up the client - selecting the
correct information and cutting and pasting...then the attachments and
adding them.

If i can however just open them up an email client with the relevent
information attached and all they have to do is click "send" then that
would be fine. Also avoids people sending us hundreds of emails for
one problem as they are "unsure" if it was sent.

Thanks for that Ben actually - it changes my approach to the whole
thing and it will be better just to use there email client and get them
to send it - rather than me firing off an email automatically and havoc
breaking loose!

Lizii.
Ben Voigt wrote:
"lizii" <cr*****@gmail. comwrote in message
news:11******** **************@ j44g2000cwa.goo glegroups.com.. .
Hey there - hopefully last newbie question i will ask for a while!
I want my application to work where you click a button - and it either:
a) open a email application - insert the correct email address and add
a subject + any attachments
or
b) just create an email and send it off with appropriate attachments
etc.

Can anyone say "abusable for spam"?


However i have a snag - i have no idea what their smtp server will be
(and the chances are, neither will they!)

i found out about mailMessage and the SmtpMail - however to send the
email i need to know the smtp.

Is there anyway of finding out from their machine what their Smtp
details are? or anyway of opening up their default mail service and
slotting in these details? I found brief glimpses about using Shell -
but not too sure about whats going on there. Better yet would be some
book or some website that gives a bit more clear idea about all of
this.

Thanks in advance!
Nov 21 '06 #4

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

Similar topics

10
4966
by: Stuart Mueller | last post by:
I have an exchange server, that I sometimes use to perform mail shots to clients on our database, these can be upwards of 1000 at a time. As we don't want different clients to see who we are working with we put these mailshots in the bcc field of the mails. This can sometimes cause a problem as we are getting alot of mails bounced back. I would like to write a script to have these emails sent out individually using the to: field of the...
1
5129
by: Ian Taylor | last post by:
Hi all... Is it possible to send RTF-formatted emails using the .NET SmtpMail implementation? I can only find provision in the BodyFormat property of the message to send plain text or HTML emails. I also have a similar problem in sending HTML/RTF emails via MAPI and would appreciate any help anyone could give me in these areas.
3
2221
by: VB Programmer | last post by:
My company has it's own webserver, which is going to host our ASP.NET web application. We want the website to be able to send out emails. 1. What do I need on the server so that it has the abillity to send out emails? It is a Windows 2000 Professional SP3 server. 2. Any examples (code, etc...) on how to send out emails via an ASP.NET webform? Thanks!
2
9221
by: Mr. x | last post by:
Hello, I am sending emails with Hebrew contents. When receiving emails - I cannot see the Hebrew characters (it is not outlook express configuration, because when receiving emails from friends - I see hebrew, it is just sending by myself using *.aspx scripts). In web.config I have the following : <configuration> <system.web>
3
1585
by: A | last post by:
Hi all! I would like to ask a question on sending emails... I have a web application that requires sending emails using email templates. The templates that I've made are separate HTML files and would require some data based on what the user has entered. Please help!!!
3
3609
by: Ant | last post by:
Hi, I'm using the MailMessage & smtpMail classes in System.Web.Mail to send mail, however it's not sending any emails. I'm using it on a Windows 2003 server. The simplest way to use this is smtpMail.Send("from@here.com", to@there.com, "Message subject", "Message Body") I'm sending it to my own email address on a different server using a dummy
8
1758
by: windandwaves | last post by:
Hi Folk I want to send out a basic newsletter from my MySql database of contacts. Does anyone know a nice and simple bit of PHP that allows me to do this? TIA - Nicolas
5
2435
by: Jai | last post by:
Hi, I am in a problem of sending mass emails(newsletter) to my website members. Actually my problem is this: I want to send newsletter to my website members. But I had given a facility for each member to choose different category of products or all products newsletter.
1
2936
by: robbiesmith79 | last post by:
Just so this is out there on the web, I battled the past 24 hours about this. Background info... I developed a ecommerce website in PHP 4 on a shared linux hosting plan from GoDaddy and had the html formatted emails sending as text/html and were going fine with limited header information. Then we moved the site over to a Dedicated Linux hosting plan. This time, it's PHP 5. Things are bound to not work as expected moving to a new...
0
1772
by: damimkader | last post by:
Hi, I'm trying to send emails using a Macro based on an Excel Sheet and the Email Client I'm using is Lotus Notes. OS used - Windows Xp. Language - VB Below is the Code I'm using for doing the same. Dim Maildb As Object
0
8173
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8679
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8621
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8475
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7159
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
4079
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4174
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2606
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1482
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.