Wrox Programmer Forums
|
Pro VB 6 For advanced Visual Basic coders working in version 6 (not .NET). Beginning-level questions will be redirected to other forums, including Beginning VB 6.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Pro VB 6 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old February 9th, 2004, 12:40 AM
Authorized User
 
Join Date: Jul 2003
Posts: 40
Thanks: 0
Thanked 1 Time in 1 Post
Default Sending Email

I need help...
How can I send an email in VB6 window apllication ??
Assume, I don't have email account profile in computer on which this application is running .
I've try to search some how-to on net but I got using such ShellExecute or MAPI that both are require email account profile in such program like Outlook Express.
Please help me to find out..
Thanks a lot.

 
Old February 9th, 2004, 09:00 AM
Authorized User
 
Join Date: Jun 2003
Posts: 54
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Try this:

Set objOutlookMsg = objOutlook.CreateItem(olMailItem)
With objOutlookMsg
    .BCC = strTO
    .Subject = txtSubject.Text
    .Body = txtBody.Text
    .Importance = olImportanceHigh

    .Send

End With

Renee C. Walker
 
Old February 9th, 2004, 10:27 PM
Authorized User
 
Join Date: Jul 2003
Posts: 40
Thanks: 0
Thanked 1 Time in 1 Post
Default

Is there other solution ?
Or how can I set up profile about sender in VB6 window application before using outlook object ?

 
Old February 11th, 2004, 10:41 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 231
Thanks: 0
Thanked 0 Times in 0 Posts
Default

You could use the Microsoft Winsock Control and connect to the SMTP server manually. You will have to learn the SMTP commands and message structures however. Take a look at RFC 821 for more information. It is not very difficult at all, however it will take a while to learn.

Regards
Owain Williams





Similar Threads
Thread Thread Starter Forum Replies Last Post
Sending EMAIL charleshua BOOK: ASP.NET 2.0 Website Programming Problem Design Solution ISBN: 978-0-7645-8464-0 16 September 3rd, 2008 12:27 AM
Sending email maitias C# 2005 2 February 17th, 2006 11:24 AM
sending email keyvanjan Classic ASP Components 1 May 9th, 2005 05:56 PM
email sending msrnivas .NET Web Services 6 June 26th, 2004 06:59 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.