Hi,
I am a moderator for the Distribution list (DL). I do receive lots of mail daily to distribute various DLs. Before I forward the message I add text on the top not to reply me and to contact the person who has signed the mail (or the mail address extract from the original message).
My requirement is to add few custom buttons on my standard tool bar depending upon the mail I click on the button and it will do all the task, i.e add the text, put the right DL address to forward the mail and send it and file it to the right folder from the sent item folder.
The mails come either in HTML format or in RTF format. I tried below code
Set objOutlook = CreateObject("Outlook.Application")
Set objInspector = objOutlook.ActiveInspector
' Check and see if anything is open.
If Not objInspector Is Nothing Then
' Get the current item.
Set objItem = objInspector.CurrentItem
' Get the current date and time.
strDateTime = Now()
objItem.Body = strDateTime & objItem.Body
End if
The above code has two drawbacks,
1. I need to open the mail either clicking the forward button or by double click the mail.
2. It changes the format of the mail. (i.e. looses all color settings in RTF, html codes visible etc)
As I have set to see mails in “View Pane” I can see the mails by clicking the mail list and can decide which button I need to press.
Thanks
I am a moderator for the Distribution list (DL). I do receive lots of mail daily to distribute various DLs. Before I forward the message I add text on the top not to reply me and to contact the person who has signed the mail (or the mail address extract from the original message).
My requirement is to add few custom buttons on my standard tool bar depending upon the mail I click on the button and it will do all the task, i.e add the text, put the right DL address to forward the mail and send it and file it to the right folder from the sent item folder.
The mails come either in HTML format or in RTF format. I tried below code
Set objOutlook = CreateObject("Outlook.Application")
Set objInspector = objOutlook.ActiveInspector
' Check and see if anything is open.
If Not objInspector Is Nothing Then
' Get the current item.
Set objItem = objInspector.CurrentItem
' Get the current date and time.
strDateTime = Now()
objItem.Body = strDateTime & objItem.Body
End if
The above code has two drawbacks,
1. I need to open the mail either clicking the forward button or by double click the mail.
2. It changes the format of the mail. (i.e. looses all color settings in RTF, html codes visible etc)
As I have set to see mails in “View Pane” I can see the mails by clicking the mail list and can decide which button I need to press.
Thanks