June 14, 2016

VBS Script for Outlook Email Message

Simple tip, this Visual Basic (VBS) script is used to open a new Outlook email message and automatically populate to: and subject:.

' Sleep for 3 minutes
WScript.Sleep(1000 * 60 * 30)
Set oolApp = CreateObject("Outlook.Application")
Set email = oolApp.CreateItem(0)
email.Recipients.Add("user@somedomain.org")
email.Subject = "Subject for email"
email.Display()


Enjoy!