Unsubscribe code for newsletter
Hi I am starting up a monthly newsletter and want to add a unsubscribe button in Vba
I can get the button in position but need the code. Help appreciated.
I have written this but it needs editing.
Sub UnsubEmail ()
Dim c1App As Outlook.Application
Dim c1Mail As Outlook.MailItem
Set c1App = CreateObject(“Outlook.Application”)
Set c1Mail = c1App.CreateItem(c1MailItem)
c1Mail.To = My Email
c1mail.Subject = “Unsubscribe”
c1Mail.Body = “Unsubscribe this person”
c1Mail.Send
‘Clean Up
Set c1App = Nothing
Set c1Mail = Nothing
End Sub
Last edited by Browny38; 01-03-2019 at 05:19 PM.
|