约会对象已发送
Backgorund:
我需要发送一个预约,一切正常,但是,如果邀请被发送,我希望得到Outlook.AppointmentItem的“已发送”属性 – 单击显示的窗口或服务器问题后,用户可以取消。
解决scheme尝试
当我读到约会有一个被保存的财产时,这当然不会告诉我它是否被发送或不像MailItem中的那个。
我不认为提供代码会有所帮助,但在这里是:
码:
昏暗的olApp作为Outlook.Application Dim olAgenda As Outlook.AppointmentItem 设置olApp =新的Outlook.Application 设置olAgenda = olApp.CreateItem(1) 随着olAgenda .Subject =“testing” .Recipients.Add =“sample@domain.com” 。显示 在错误恢复下一步 调用.ItemProperties.Item(“Saved”)'这里是我需要赶上那种“被发送? variables。 如果Err.Number = 0那么'99。 如果错误 MsgBox“项目发送” 其他'99。 如果错误 MsgBox“项目不发送” 结束如果'99。 如果错误 结束
PS:请注意,我不喜欢后期绑定,必须添加outlook库的引用。
题:
如果AppointmentItem被发送,我怎么能抓到?
约会本身永远不会发送 – 它保留在日历文件夹中。 只有MeetingItem
对象被发送。
这就是说,使用AppointmentItem.MeetingStatus属性。