为什么我的Outlook项目的创建时间属性返回任意日期?
当我运行以下模块时,我将获得一个显示“ 1/1/4051”的消息框。
Sub CreateNoteItem()
Dim olApp As Outlook.Application
Dim olNS As Outlook.NameSpace
Dim olNoteItm As Outlook.NoteItem
Set olApp = Outlook.Application
Set olNS = olApp.GetNamespace("MAPI")
Set olNoteItm = olApp.CreateItem(olNoteItem)
MsgBox olNoteItm.CreationTime
End Sub
我期望的日期值,例如44701等,或类似于“现在”显示的字符串(m/dd/yyyy hh:mm:ss)。
这不仅是出于注释项目,还发生在邮寄项目中。我的最终目标是使用此创建时间,然后随后创建时间处理任何项目。
谢谢!
when I run the below module, I get a message box displaying "1/1/4051".
Sub CreateNoteItem()
Dim olApp As Outlook.Application
Dim olNS As Outlook.NameSpace
Dim olNoteItm As Outlook.NoteItem
Set olApp = Outlook.Application
Set olNS = olApp.GetNamespace("MAPI")
Set olNoteItm = olApp.CreateItem(olNoteItem)
MsgBox olNoteItm.CreationTime
End Sub
I was expecting a date value such as 44701, etc., or a string similar to when I display "Now" (m/dd/yyyy hh:mm:ss).
This happens not just for note items, but also mail items. My end goal is to use this creation time to then process any items with later creation times.
Thanks!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
在获取任何特定日期的属性之前,请调用
保存
方法。Call the
Save
method before getting any date-specific properties.