![]() |
If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
![]()
Would like to create macro to forward message adding the following text to
body. "Sue" "Please approve enclosed forecast change request and forward to Bops" "Regards" "Phil" Writing macro to forward is straight forward but struggling to work out how to add text. Would like add text to be in bold and coloured blue. |
#2
|
|||
|
|||
![]()
Am Fri, 14 Jul 2006 06:16:03 -0700 schrieb Phil Best:
You can call an MailItem“s Forward function which returns a new MailItem object. Then you can write into its HTMLBody property, example inserts your text at the top: HTMLBody = "Your text" & vbCRLF & HTMLBody For the formatting you need to enclose your text in the proper HTML tags. b is for bold, color=#0000ff is for blue. -- Viele Gruesse / Best regards Michael Bauer - MVP Outlook -- www.VBOffice.net -- Would like to create macro to forward message adding the following text to body. "Sue" "Please approve enclosed forecast change request and forward to Bops" "Regards" "Phil" Writing macro to forward is straight forward but struggling to work out how to add text. Would like add text to be in bold and coloured blue. |
#3
|
|||
|
|||
![]()
Dose not seem to work. Happy to admit that VB is not my best skill. I enclose
the script I am using and would be obliged if you would advise where I am going wrong. Sub Forward() On Error Resume Next Set ThisItem = Application.ActiveInspector.CurrentItem Set FwdItem = ThisItem.Forward FwdItem.To = " HTMLBody = "Your text" & vbCrLf & HTMLBody FwdItem.Send End Sub "Michael Bauer" wrote: Am Fri, 14 Jul 2006 06:16:03 -0700 schrieb Phil Best: You can call an MailItemĀ“s Forward function which returns a new MailItem object. Then you can write into its HTMLBody property, example inserts your text at the top: HTMLBody = "Your text" & vbCRLF & HTMLBody For the formatting you need to enclose your text in the proper HTML tags. b is for bold, color=#0000ff is for blue. -- Viele Gruesse / Best regards Michael Bauer - MVP Outlook -- www.VBOffice.net -- Would like to create macro to forward message adding the following text to body. "Sue" "Please approve enclosed forecast change request and forward to Bops" "Regards" "Phil" Writing macro to forward is straight forward but struggling to work out how to add text. Would like add text to be in bold and coloured blue. |
#4
|
|||
|
|||
![]()
Am Mon, 17 Jul 2006 01:07:02 -0700 schrieb Phil Best:
Please write FwdItem.HTMLBody instead of HTMLBody. -- Viele Gruesse / Best regards Michael Bauer - MVP Outlook -- www.VBOffice.net -- Dose not seem to work. Happy to admit that VB is not my best skill. I enclose the script I am using and would be obliged if you would advise where I am going wrong. Sub Forward() On Error Resume Next Set ThisItem = Application.ActiveInspector.CurrentItem Set FwdItem = ThisItem.Forward FwdItem.To = " HTMLBody = "Your text" & vbCrLf & HTMLBody FwdItem.Send End Sub "Michael Bauer" wrote: Am Fri, 14 Jul 2006 06:16:03 -0700 schrieb Phil Best: You can call an MailItem“s Forward function which returns a new MailItem object. Then you can write into its HTMLBody property, example inserts your text at the top: HTMLBody = "Your text" & vbCRLF & HTMLBody For the formatting you need to enclose your text in the proper HTML tags. b is for bold, color=#0000ff is for blue. -- Viele Gruesse / Best regards Michael Bauer - MVP Outlook -- www.VBOffice.net -- Would like to create macro to forward message adding the following text to body. "Sue" "Please approve enclosed forecast change request and forward to Bops" "Regards" "Phil" Writing macro to forward is straight forward but struggling to work out how to add text. Would like add text to be in bold and coloured blue. |
#5
|
|||
|
|||
![]()
Michael
Made the change but the only text that appears on the forwarded email is "Your Text". The original text disappears. Macro enclosed Sub Forward() On Error Resume Next Set ThisItem = Application.ActiveInspector.CurrentItem Set Fwditem = ThisItem.Forward Fwditem.To = " Fwditem.HTMLBody = "Your Text" & vbCrLf & HTMLBody Fwditem.Send End Sub "Michael Bauer" wrote: Am Mon, 17 Jul 2006 01:07:02 -0700 schrieb Phil Best: Please write FwdItem.HTMLBody instead of HTMLBody. -- Viele Gruesse / Best regards Michael Bauer - MVP Outlook -- www.VBOffice.net -- Dose not seem to work. Happy to admit that VB is not my best skill. I enclose the script I am using and would be obliged if you would advise where I am going wrong. Sub Forward() On Error Resume Next Set ThisItem = Application.ActiveInspector.CurrentItem Set FwdItem = ThisItem.Forward FwdItem.To = " HTMLBody = "Your text" & vbCrLf & HTMLBody FwdItem.Send End Sub "Michael Bauer" wrote: Am Fri, 14 Jul 2006 06:16:03 -0700 schrieb Phil Best: You can call an MailItemĀ“s Forward function which returns a new MailItem object. Then you can write into its HTMLBody property, example inserts your text at the top: HTMLBody = "Your text" & vbCRLF & HTMLBody For the formatting you need to enclose your text in the proper HTML tags. b is for bold, color=#0000ff is for blue. -- Viele Gruesse / Best regards Michael Bauer - MVP Outlook -- www.VBOffice.net -- Would like to create macro to forward message adding the following text to body. "Sue" "Please approve enclosed forecast change request and forward to Bops" "Regards" "Phil" Writing macro to forward is straight forward but struggling to work out how to add text. Would like add text to be in bold and coloured blue. |
#6
|
|||
|
|||
![]()
Am Tue, 18 Jul 2006 03:18:02 -0700 schrieb Phil Best:
Fwditem.HTMLBody = "Your Text" & vbCrLf & HTMLBody At the end is another HTMLBody which needs to be full qualified. -- Viele Gruesse / Best regards Michael Bauer - MVP Outlook -- www.VBOffice.net -- Michael Made the change but the only text that appears on the forwarded email is "Your Text". The original text disappears. Macro enclosed Sub Forward() On Error Resume Next Set ThisItem = Application.ActiveInspector.CurrentItem Set Fwditem = ThisItem.Forward Fwditem.To = " Fwditem.HTMLBody = "Your Text" & vbCrLf & HTMLBody Fwditem.Send End Sub "Michael Bauer" wrote: Am Mon, 17 Jul 2006 01:07:02 -0700 schrieb Phil Best: Please write FwdItem.HTMLBody instead of HTMLBody. -- Viele Gruesse / Best regards Michael Bauer - MVP Outlook -- www.VBOffice.net -- Dose not seem to work. Happy to admit that VB is not my best skill. I enclose the script I am using and would be obliged if you would advise where I am going wrong. Sub Forward() On Error Resume Next Set ThisItem = Application.ActiveInspector.CurrentItem Set FwdItem = ThisItem.Forward FwdItem.To = " HTMLBody = "Your text" & vbCrLf & HTMLBody FwdItem.Send End Sub "Michael Bauer" wrote: Am Fri, 14 Jul 2006 06:16:03 -0700 schrieb Phil Best: You can call an MailItem“s Forward function which returns a new MailItem object. Then you can write into its HTMLBody property, example inserts your text at the top: HTMLBody = "Your text" & vbCRLF & HTMLBody For the formatting you need to enclose your text in the proper HTML tags. b is for bold, color=#0000ff is for blue. -- Viele Gruesse / Best regards Michael Bauer - MVP Outlook -- www.VBOffice.net -- Would like to create macro to forward message adding the following text to body. "Sue" "Please approve enclosed forecast change request and forward to Bops" "Regards" "Phil" Writing macro to forward is straight forward but struggling to work out how to add text. Would like add text to be in bold and coloured blue. |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Hotmail forward to Outlook XP? | ~~Nightcrawler~~ | Outlook - General Queries | 2 | March 30th 06 05:10 AM |
how to forward a distribution list in outlook | Maggie D | Outlook - Using Contacts | 1 | February 27th 06 10:24 PM |
macro to forward | Dan | Outlook and VBA | 8 | February 23rd 06 07:22 PM |
Forward all e-mails from Outlook | Maxim Kazitov | Add-ins for Outlook | 1 | January 15th 06 10:43 PM |
Forward e-mail from Outlook | Maxim Kazitov | Outlook - General Queries | 3 | January 13th 06 01:37 PM |