Now we need to be aware of what are the items we have while writing an email. Code: Set EmailItem = EmailApp.CreateItem(olMailItem) 'To launch new outlook email.Ħ. In order to launch a new email, we need to set the reference to our previous variable as CreateItem. Code: Dim EmailItem As Outlook.MailItem 'To refer new outlook email.ĥ. Now to write the email, we declare one more variable as “Outlook.MailItem”. To create a new instance of the outside object, below is the code.Ĥ. We need to create an instance of a new object separately. The above variable is an object variable. Code: Dim EmailApp As Outlook.Application 'To refer to outlook application.ģ. Declare the variable Outlook.Application. Code: Sub SendEmail_Example1() End Sub.Ģ.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |