G
Guest
I got the code shown below from the Outlook CHM and it works. My problem is
that it opens a security dialog with a first line that begins: "A program is
trying to automatically send e-mail......" I would like to suppress this
message but cannot find any property in the the Object model that does this
or anywhere in the Options dialog of Outlook itself that permits Automation
applications to be trusted. Any help would be appreciated.
Private Sub CommandButton1_Click()
Dim myMail As Outlook.MailItem
Set myMail = Outlook.Application.CreateItem(olMailItem)
With myMail
.To = "(e-mail address removed)"
.Subject = "Book overdue: " & "Gone with the Wind"
.Body = "Please return this book as soon as possible."
End With
myMail.Send
End Sub
that it opens a security dialog with a first line that begins: "A program is
trying to automatically send e-mail......" I would like to suppress this
message but cannot find any property in the the Object model that does this
or anywhere in the Options dialog of Outlook itself that permits Automation
applications to be trusted. Any help would be appreciated.
Private Sub CommandButton1_Click()
Dim myMail As Outlook.MailItem
Set myMail = Outlook.Application.CreateItem(olMailItem)
With myMail
.To = "(e-mail address removed)"
.Subject = "Book overdue: " & "Gone with the Wind"
.Body = "Please return this book as soon as possible."
End With
myMail.Send
End Sub