Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 788
Default Formatting e-mails after creation

Is it possible to format an e-mail after it has been created with VB in excel?
I want to make part of the text Red. is it also possible to change the font?
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,120
Default Formatting e-mails after creation

To format an email you need to use the "HTMLBody" Property.

--
HTH

Bob Phillips

"Chris" wrote in message
...
Is it possible to format an e-mail after it has been created with VB in

excel?
I want to make part of the text Red. is it also possible to change the

font?


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,123
Default Formatting e-mails after creation

Hi Chris

You must use the HTMLBody then instead if Body

Why don't you create it on a worksheet and send it the way it is
http://www.rondebruin.nl/mail/folder3/mail2.htm



--
Regards Ron de Bruin
http://www.rondebruin.nl


"Chris" wrote in message ...
Is it possible to format an e-mail after it has been created with VB in excel?
I want to make part of the text Red. is it also possible to change the font?



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 788
Default Formatting e-mails after creation

Thanks, but i've never used HTMLBody?

"Bob Phillips" wrote:

To format an email you need to use the "HTMLBody" Property.

--
HTH

Bob Phillips

"Chris" wrote in message
...
Is it possible to format an e-mail after it has been created with VB in

excel?
I want to make part of the text Red. is it also possible to change the

font?



  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Formatting e-mails after creation


Chris

It isn't difficult to use HTMLBody.

Code:
--------------------

Dim myOlapp As New Outlook.Application
Dim myOLItem As Outlook.MailItem
Dim myVar As Integer

Set myOLItem = myOlapp.CreateItem(olMailItem)
myVar = 12
With myOLItem
.Subject = "Some Subject"
.HTMLBody = "<pYour score was <b" & myVar & "</b</p"
.HTMLBody = .HTMLBody & "<pNext line</p"
.To = "
.Display
End With
--------------------


--
Norie
------------------------------------------------------------------------
Norie's Profile: http://www.excelforum.com/member.php...o&userid=19362
View this thread: http://www.excelforum.com/showthread...hreadid=378405



  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,120
Default Formatting e-mails after creation

Then you can also use some formatting tags such as bold and font.

--
HTH

Bob Phillips

"Norie" wrote in
message ...

Chris

It isn't difficult to use HTMLBody.

Code:
--------------------

Dim myOlapp As New Outlook.Application
Dim myOLItem As Outlook.MailItem
Dim myVar As Integer

Set myOLItem = myOlapp.CreateItem(olMailItem)
myVar = 12
With myOLItem
.Subject = "Some Subject"
.HTMLBody = "<pYour score was <b" & myVar & "</b</p"
.HTMLBody = .HTMLBody & "<pNext line</p"
.To = "
.Display
End With
--------------------


--
Norie
------------------------------------------------------------------------
Norie's Profile:

http://www.excelforum.com/member.php...o&userid=19362
View this thread: http://www.excelforum.com/showthread...hreadid=378405



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Coma between two e-mails Hemang Excel Discussion (Misc queries) 3 May 13th 10 10:30 PM
Finding e-mails James Excel Worksheet Functions 0 February 11th 09 11:15 AM
Opening e-mails HarleyB Excel Discussion (Misc queries) 2 January 23rd 09 06:21 PM
send e-mails bra863 Excel Discussion (Misc queries) 1 August 22nd 08 04:28 PM
e-mails addresses thd3 Excel Worksheet Functions 1 October 8th 07 09:20 PM


All times are GMT +1. The time now is 11:59 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"