G
Guest
Hello All - I am using the Send_Range code provided by Microsoft to send an
Excel worksheet range as an email. This works great, but, because this is
always a two-week schedule that is sent, I was hoping I could add options to
expire the message "two weeks from today". Any ideas or referrals to links,
books, for help adding to this code will be greatly appreciated.
Thank you. Annie
Sub Send_Range()
' Select the range of cells on the active worksheet.
ActiveSheet.Range("A3:F20").Select
' Show the envelope on the ActiveWorkbook.
ActiveWorkbook.EnvelopeVisible = True
' Set the optional introduction field thats adds
' some header text to the email body. It also sets
' the To and Subject lines. Finally the message
' is displayed.
With ActiveSheet.MailEnvelope
.Introduction = "Personnel on Call This Week and Next Week"
.Item.To = "oncall_list"
.Item.Subject = "Personnel on Call This Week and Next Week"
.Item.Display
End With
End Sub
Excel worksheet range as an email. This works great, but, because this is
always a two-week schedule that is sent, I was hoping I could add options to
expire the message "two weeks from today". Any ideas or referrals to links,
books, for help adding to this code will be greatly appreciated.
Thank you. Annie
Sub Send_Range()
' Select the range of cells on the active worksheet.
ActiveSheet.Range("A3:F20").Select
' Show the envelope on the ActiveWorkbook.
ActiveWorkbook.EnvelopeVisible = True
' Set the optional introduction field thats adds
' some header text to the email body. It also sets
' the To and Subject lines. Finally the message
' is displayed.
With ActiveSheet.MailEnvelope
.Introduction = "Personnel on Call This Week and Next Week"
.Item.To = "oncall_list"
.Item.Subject = "Personnel on Call This Week and Next Week"
.Item.Display
End With
End Sub