473,394 Members | 1,828 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.

Need help sending email programmatically

Hi all

I'm writing a small app that needs to be in C++ and needs to send email
from inside the program. I can do this easily in PHP, Perl and Java,
but have no clue how to do it in C++.

Does anyone know of free code I look at that incorporates this
function? Basically, I need to send a simple email to the system
support if something goes wrong in the program. The program will be
running on Windows and I'll be compiling it under MinGW.

Any and all help is much appreciated.

Thanks

May 11 '06 #1
14 6496
Rostau wrote:
I'm writing a small app that needs to be in C++ and needs to send
email from inside the program. I can do this easily in PHP, Perl and
Java, but have no clue how to do it in C++.
Well, that's understandable. There is no way to do it in C++. You need
to use some kind of OS-specific facility.
Does anyone know of free code I look at that incorporates this
function?
Plenty. Have you ever heard of www.google.com?
Basically, I need [..]


Whatever.

V
--
Please remove capital 'A's when replying by e-mail
I do not respond to top-posted replies, please don't ask
May 11 '06 #2
"Rostau" <ev********@ananzi.co.za> wrote in message
news:11**********************@i40g2000cwc.googlegr oups.com...
Hi all

I'm writing a small app that needs to be in C++ and needs to send email
from inside the program. I can do this easily in PHP, Perl and Java,
but have no clue how to do it in C++.

Does anyone know of free code I look at that incorporates this
function? Basically, I need to send a simple email to the system
support if something goes wrong in the program. The program will be
running on Windows and I'll be compiling it under MinGW.


A few ways depending on how you want to do it. One way is to open a socket
connection to your SMTP server and send the message that way. The otherway
is to interface with some system e-mail software.

Both are rather off topic here though. Start googling for both solutions
and pick the one you want. If you have problems implementing it because
you're code isn't working, that's on topic.
May 11 '06 #3
Thanks for basically being a rude git. If you didn't have anything to
contribute, why did you bother posting? Techno-arrogance is for
wankers. Way to encourage people to learn things, dickhead.

May 12 '06 #4
Thanks for this. For the record, I have googled. I was hoping someone
had knowledge of a piece of working code that does this simple task and
was free to distribute. Google throws up a variety of libraries, most
of which seem to do far more than what I want, which is simply build
email, connect to server, send mail.

Thanks anyway.

May 12 '06 #5
Rostau schrieb:
Hi all

I'm writing a small app that needs to be in C++ and needs to send email
from inside the program. I can do this easily in PHP, Perl and Java,
but have no clue how to do it in C++.

Does anyone know of free code I look at that incorporates this
function? Basically, I need to send a simple email to the system
support if something goes wrong in the program. The program will be
running on Windows and I'll be compiling it under MinGW.

Any and all help is much appreciated.


Maybe this has what you need:

http://www.appinf.com/docs/poco/
(http://www.appinf.com/docs/poco/Net....ntSession.html)

HTH
Stefan
--
Stefan Naewe
naewe.s_AT_atlas_DOT_de
May 12 '06 #6
Looks great. Thanks a lot :-)

May 12 '06 #7
Rostau wrote:
Thanks for basically being a rude git. If you didn't have anything to
contribute, why did you bother posting? Techno-arrogance is for
wankers. Way to encourage people to learn things, dickhead.


You do know that your posts are archived for posterity, don't you? I
really want to congratulate you on your success for potentially screwing
your career when a prospective employer of yours reads your posts. Name
calling is for children. Way to behave on the 'net with strangers.

FOr the record, I did contribute. At least now you know that if you
misbehave, you will face unpleasantness, even if it's just in the form of
irritation after reading replies to your messages. Read the FAQ, read
the newsgroup before continuing to embarrass yourself. Learn what
topicality is and how to communicate with other people without offending
them. And meanwhile, welcome to my killfile.
May 12 '06 #8
"Rostau" <ev********@ananzi.co.za> wrote in message
news:11**********************@i40g2000cwc.googlegr oups.com...
Thanks for this. For the record, I have googled. I was hoping someone
had knowledge of a piece of working code that does this simple task and
was free to distribute. Google throws up a variety of libraries, most
of which seem to do far more than what I want, which is simply build
email, connect to server, send mail.

Thanks anyway.


Try sourceforge.
May 12 '06 #9
Rostau wrote:
Thanks for basically being a rude git. If you didn't have anything to
contribute, why did you bother posting? Techno-arrogance is for
wankers. Way to encourage people to learn things, dickhead.


*plonk*

Brian
May 12 '06 #10
Default User wrote:
Rostau wrote:
Thanks for basically being a rude git. If you didn't have anything to
contribute, why did you bother posting? Techno-arrogance is for
wankers. Way to encourage people to learn things, dickhead.


*plonk*


This is why I often post "how to bounce a post". My bounces generally don't
draw flames, regardless how stupid the OP is.

--
Phlip
http://www.greencheese.us/ZeekLand <-- NOT a blog!!!
May 12 '06 #11

Rostau wrote:
Thanks for this. For the record, I have googled. I was hoping someone
had knowledge of a piece of working code that does this simple task and
was free to distribute. Google throws up a variety of libraries, most
of which seem to do far more than what I want, which is simply build
email, connect to server, send mail.

Thanks anyway.


You need to read the RFC's on email protocols, of which there are quite
a few, and then read how to make a network connection and communicate
through it using the facilities provided by your target OS.

Or you could always use one of those libraries...

May 12 '06 #12
Phlip wrote:
Default User wrote:
Rostau wrote:
Thanks for basically being a rude git. If you didn't have anything to >> contribute, why did you bother posting? Techno-arrogance is for wankers. Way to encourage people to learn things, dickhead.


plonk


This is why I often post "how to bounce a post". My bounces generally
don't draw flames, regardless how stupid the OP is.

You're a man among men.

Brian
May 12 '06 #13
Your sad attempt to save face has failed. You were downright rude and
you know it, so trying to take the moral high ground isn't going to get
you anywhere. You're obviously a pathetic slob with self-esteem so low
he has to mock people who know less than he does.

May 14 '06 #14
looks like you DO LOVE feeding the trolls

May 15 '06 #15

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

Similar topics

3
by: Mike Gorgone | last post by:
Hi All, I'm currently sending email with a backend program that is being used to monitor data in a SQL2000 database. Basically I'm trying to figure out how to add a link to the email body...
2
by: Ron Harter | last post by:
I am developing a C# windows application that will allow a user to send an e-mail to an SMS server when events happen in the system. I was going to use System.Web.Mail namespace and use the...
13
by: joe215 | last post by:
I want my users to send emails from a Windows app that I am developing in Visual Basic.NET 2003. I found a good example of sending email to a SMTP server using the SmtpMail class. However, using...
2
by: Nathan Sokalski | last post by:
I would like to be able to send the user to another URL programmatically. Because the destination URL is not known until runtime, I cannot use the Response.Redirect method. I do not want to use the...
3
by: UJ | last post by:
I'm way out of my league here but I'm having problems sending e-mails programmatically. I have a web app that will allow users to have e-mail sent to them (forgotten password/resetting password,...
5
by: trevisc | last post by:
Good afternoon everyone. I'm currently trying to build an automated invoice system that collects dynamic data and automatically sends out invoices. In my test database I have 23 companies that...
4
by: squishy | last post by:
I want to check an emailbox (that does not offer forwarding functions) and forward the mail in it to my new account. That's not a problem. But, I want the mails that I forward to my new email...
5
by: =?Utf-8?B?VG9ueSBXaXNzbGVy?= | last post by:
Hello everyone- I am hoping a couple of you will have some ideas on this one... I have a webform created in visual basic 2005. Basically, the webform gather answers to the questions asked on...
1
by: sasnien | last post by:
Hello All, I have an Access '97 application that I currently have mail enabled and sending properly. However, I want to add functionality to effectively create a 30 day tickler, that would walk...
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: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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
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...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
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.