Email - Sending/Recieving With Pop3 & SMTP

Hi,
I need to know how to send and recieve email from a POP3 or SMTP server, without using MAPI.  If you can find a freeware control for me that would do this (with good documentation), that would be fine.  If you can't find a control, please explain how I can send and recieve mail.  It would be helpful also if you explained how to parse the headers - subject, date, from, to, etc.
Thanks!
-Mark
LVL 1
eversoslightlyAsked:
Who is Participating?

Improve company productivity with a Business Account.Sign Up

x
 
inthrallConnect With a Mentor Commented:
The following address is to a freeware control with a sample app. and some documentation.

http://ftp.univie.ac.at/mirror/simtelnet/win95/visbasic/maillite.zip


0
 
eversoslightlyAuthor Commented:
Please use detail in your answer - it is worth 150 points!
I forgot to add this initially - I use VB5 Enterprise Edition.
0
 
eversoslightlyAuthor Commented:
I now have found one:
(http://www.kiosknet.org/vb/files/samples/16/pop_smtp.zip)
But I found that it did not allow attachments, or files over 64k.  Attachments are a must for me.
0
What Kind of Coding Program is Right for You?

There are many ways to learn to code these days. From coding bootcamps like Flatiron School to online courses to totally free beginner resources. The best way to learn to code depends on many factors, but the most important one is you. See what course is best for you.

 
vbklausCommented:
Hi, for sending mail I use AspMail. It is a small control that was designed to be used on IIS Active Server Pages, but it also works with VB on any standard computer. A computer with automatic internet connection can send email without using MAPI and without disturbing the user. This OCX can not find the MX host for the recipients domain! But I use another SMTP server (there are many that still do it) for relaying the emails.
If you do not like to do so, you can also buy AspMX to find MX host names.
ASPmail works reliable and easy, like : MyMailserver.FromName ="Klaus"   MyMailserver.Subject = "Testmessage"....
Well, it is quite expensive, about $45 per single license. Their web-site is www.serverobjects.com
When you look around on their web pages (links to other ASP sites), you will also find other free SMTP objects. But I have no experien
0
 
vbklausCommented:
Hi, I just rerad you next message: ASP mail can send attachments (UUENCODE or MIME) -Klaus
0
 
eversoslightlyAuthor Commented:
Both of those are not freeware - there must be documentation or a control for free somewhere on this subject - it is a quite broad concept - Thanks anyway.
0
 
vbklausCommented:
SMTP: Then have a look at
'OCX Mail/ASP by Flicks (FREE)
SMTP mail including attachments.
available at http://www.flicks.com/ASPMail/'
or other sources as seen on page
http://www.activeserverpages.com/components/freemail.asp.

The WINSOCK control is part of VB (= free)



0
 
eversoslightlyAuthor Commented:
I just found another free one, yet still, without attachments:
http://getit.at/freeocxsite/
0
 
eversoslightlyAuthor Commented:
Now the question is, how do I get mail (pop), with attachments?
0
 
eversoslightlyAuthor Commented:
If you can tell me how to do this with the Winsock control, that would be great too.
0
 
eversoslightlyAuthor Commented:
For now, to leave the board open, I'm rejecting the answer.  If someone else gives me the rest of the answer, I will still give you points for the help you've given me so far.
0
 
vbklausCommented:
When you contact the POP3 server with the WINSOCK control on port 110 and enter RETR [mess.no.]
You will not only receive text, but always also with any attachments. They are part of the message and appear as hundreds of letters (text encoded).
You can find that part of the message from VB (where the encoded binary data begins), when you look for the adequate keywords in the message.
You need to decode these letters to binary data. (I remember DOS ZIP had an option to do such things)
0
 
vbklausCommented:
Hello; my first message was truncated. This is my experience with receiving mail with the WINSOCK control of VB: Set it to remote port 110. Connect to the POP3 server and wait for the answer of the remote.
If the first sing is a '+', then you are connected. Then you send the POP3 commands (user Klaus[ENTER]...)(Get the RFC document to find all the POP3 commands). Every time you receive a '+' as the first sign, the command has been executed from the POP3 server.
It has been quite easy to connect and log in. But I had much
trouble with converting: Some (many!) messages are not plain ASCII text,but ISO (get another RFC document) or HTML. You need to take care for the conversion so the received email will look fine ! If it is for another/private purpose, you will not need to care much for that.
The winsock control can also connect to the SMTP port of a server and send messages !
0
 
thespisCommented:
Just out of morbin curiosity, why are you opposed to using the MAPI?  Thanks...

Terrence
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.