Introduction 属性
优质
小牛编辑
125浏览
2023-12-01
设置或返回使用 MsoEnvelope 对象发送的文档中包含的介绍性文本。介绍性文本包含于电子邮件中文档的顶部。String 类型,可读写。
expression.Introduction
expression 必需。该表达式返回“应用于”列表中的对象之一。
示例
本示例将活动的 Microsoft Word 文档以电子邮件发送到传递给子例程的电子邮件地址。
Sub SendMail(ByVal strRecipient As String)
'Use a With...End With block to reference the MsoEnvelope object.
With Application.ActiveDocument.MailEnvelope
'Add some introductory text before the body of the e-mail.
.Introduction = "Please read this and send me your comments."
'Return a MailItem object that you can use to send the document.
With .Item
'All of the mail item settings are saved with the document.
'When you add a recipient to the Recipients collection
'or change other properties these settings will persist.
.Recipients.Add strRecipient
.Subject = "Here is the document."
'The body of this message will be
'the content of the active document.
.Send
End With
End With
End Sub