Solved

Sending email through VB application

Posted on 1998-09-09
3
111 Views
Last Modified: 2010-04-30
What is the best/simplest way to send emails through VB, preferably without third-part components?
0
Comment
Question by:ribbegrd
3 Comments
 
LVL 4

Expert Comment

by:mcix
ID: 1433858
What kind of e-mail would you like to send?

SMTP,MAPI?
0
 
LVL 15

Accepted Solution

by:
Eyal earned 50 total points
ID: 1433859
here is some code from source code site

'Code provided by Planet Source Code(tm) 'as is', without
'     warranties as to performance, fitness, merchantability,
'     and any other warranty (whether expressed or implied).
'****************************************************************

'Instead of writing declarations and everything to open a we
'     b browser to your 'page try this:

Ret = Shell("Start.exe " & "www.send-a-teddy.com/lc", 0)


'The program start.exe executes the shell for any program in
'      windows95, try this:

Ret = Shell("Start.exe " & "mailto:lc-enterprises@usa.net", 0)

'The line above will open the default mail client with your
'     address on it, also:

Ret = Shell("Start.exe " & "mailto:lc-enterprises@usa.net?Subject=Hello", 0)

'With the subject "Hello" already filled.

'The following line will open an html file with the default
'     browser:

Ret = Shell("Start.exe " & "c:\hellopage.htm", 0)

'If you have a program with a filelist box, try this to open
'      the shell of a file with a double click event:

Ret = Shell("Start.exe " & """" & Filepath & Filelist1 & """", 0)


0
 

Author Comment

by:ribbegrd
ID: 1433860
SMTP mail is preferred. Maybe that 'sendmail' would be useful?
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now