TaskItem.BeforeAttachmentAdd 事件 (Outlook)TaskItem.BeforeAttachmentAdd Event (Outlook)

附件添加到父对象的实例前发生。Occurs before an attachment is added to an instance of the parent object.

语法Syntax

expressionexpression. BeforeAttachmentAdd( _Attachment_ , _Cancel_ )

_表达式_一个表示TaskItem对象的变量。expression A variable that represents a TaskItem object.

参数Parameters

名称Name 必需/可选Required/Optional 数据类型Data type 说明Description
AttachmentAttachment 必需Required AttachmentAttachment 向项目添加附件The Attachment to be added to the item.
CancelCancel 必需Required BooleanBoolean 设置为True以取消操作;否则,设置为False以允许添加附件Set to True to cancel the operation; otherwise, set to False to allow the Attachment to be added.

另请参阅See also

TaskItem 对象TaskItem Object