Send mail using HTML 
Author Message
 Send mail using HTML

**** Example ****

Dim objOLApp as Outlook.Application
Dim objMail as Outlook.MailItem

Set objOLApp = CreateObject("Outlook.Application")
Set objMail = objOLApp.CreateItem(olMailItem)

With objMail
  ' When adding a recipient, it always defaults to TO
  .Recipients.Add ("Display Name or email addy")
  .Subject = "First message from automation"
  .HTMLBody = "<HTML><BODY>Hello from VB 5/6 when using
automation.</BODY></HTML>"
End With
' Send it
'objMail.Send

' Display it
objMail.Display

**** End Example ****

Don't forget to add a reference to the Outlook object model in your project.

Quote:

> Can someone tell me how I can send an Outlook e-mail in HTML using VB 5/6?
> Examples would be a great help.

> Thanks in advance!

> MD



Sun, 21 Jul 2002 03:00:00 GMT  
 
 [ 1 post ] 

 Relevant Pages 

1. Send Mail using HTML

2. Send mail using HTML

3. Send mail using HTML

4. sending HTML-Mail with images and not using ActiveDocument.send

5. sending html mail from asp page using mailmessage

6. Sending HTML Mail Messages using MAPI Controls

7. Send E-Mail using HTML format...

8. Help sending HTML mail in mail merge

9. Sending mail in RTF whiteout using mail merge?

10. Send e-mail using default e-mail client

11. Sending mail without using MS Outlook or other mail client

12. Sending mail using visual basic to Internet mail addresses

 

 
Powered by phpBB® Forum Software