Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

create an html email in vb ?

Posted on 2004-11-18
8
Medium Priority
?
141 Views
Last Modified: 2010-05-02
Hi
at the moment my little app is creating a email in plain text, but
i need to be able to add fonts,colors, and mybe some small images into the body of the email.
Very similar to the html question notifications we receive from experts exchange on our questions -

thanks a
stack\


cheers
0
Comment
Question by:CraigLazar
6 Comments
 
LVL 97

Expert Comment

by:Lee W, MVP
ID: 12615786
Use CDONTS (or possibly CDO, as CDONTS is being phased out).
0
 
LVL 97

Accepted Solution

by:
Lee W, MVP earned 200 total points
ID: 12615793
0
 
LVL 70

Expert Comment

by:Éric Moreau
ID: 12616594
I use http://www.freevbcode.com/ShowCode.Asp?ID=109 to send HTML e-mails.
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 28

Expert Comment

by:vinnyd79
ID: 12620852
If you use Outlook you can try something like this:


Private Sub Command1_Click()
Dim objOutlook As Object
Dim objOutlookMsg As Object
Set objOutlook = CreateObject("Outlook.Application")
Set objOutlookMsg = objOutlook.CreateItem(0)

With objOutlookMsg
    .To = "someone@somewhere.com"
    .Cc = "someoneelse@somewhere.com"
    .Subject = "Hello......"
    .Body = "This is the body of message"
    .HTMLBody = "<H1>HTML version of message</H1>"
  '  .Attachments.Add ("c:\myFileToSend.txt")
    .Send
End With

Set objOutlookMsg = Nothing
Set objOutlook = Nothing
End Sub
0
 
LVL 4

Author Comment

by:CraigLazar
ID: 12655014
hi guys
thanks a stack, sorry i have been hectic,
will get to it now

thanks

cheers
0
 
LVL 4

Author Comment

by:CraigLazar
ID: 12911044
Hi
so sorry been away and so busy,
i have this week to go thru this stuff, canu please leave the question open for this
week and i promise to close it up by the ned of the week

thanks so much
Sorry to the experts who have helped here
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
Introduction While answering a recent question (http://www.experts-exchange.com/Q_27402310.html) in the VB classic zone, I wrote some VB code in the (Office) VBA environment, rather than fire up my older PC.  I didn't post completely correct code o…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
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…
Suggested Courses
Course of the Month21 days, 6 hours left to enroll

810 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