【问题标题】:Schema name for the message date property消息日期属性的架构名称
【发布时间】:2017-12-30 23:04:59
【问题描述】:

我正在尝试通过 PropertyAccessor 读取和写入消息日期(发送/接收),但无法弄清楚该属性的架构名称是什么,甚至不确定我是否正确传递了架构参数.

什么是正确的架构名称?
如何正确传递GetProperty()SetProperty() 的参数?
某处是否有每个属性的可用名称列表?
有没有什么方法可以在没有模式的情况下获取/设置属性,而只需使用属性名称?

object prop = item.PropertyAccessor.GetProperty("http://schemas.microsoft.com/mapi/proptag/0x10130102"); // I know 0x10130102 is not correct but don't know what the correct one is.

item.PropertyAccessor.SetProperty("http://schemas.microsoft.com/mapi/proptag/0x10130102", DateTime.Now.ToFileTimeUtc());

【问题讨论】:

    标签: c# outlook vsto outlook-addin


    【解决方案1】:

    这是电子邮件属性的完整列表(可能的候选人以BOLD):

    "PR_MESSAGE_CLASS" "http://schemas.microsoft.com/mapi/proptag/0x001A001E"

    “PR_SUBJECT”“http://schemas.microsoft.com/mapi/proptag/0x0037001E

    “PR_CLIENT_SUBMIT_TIME”http://schemas.microsoft.com/mapi/proptag/0x00390040

    “PR_SENT_REPRESENTING_SEARCH_KEY”“http://schemas.microsoft.com/mapi/proptag/0x003B0102

    “PR_SUBJECT_PREFIX PT_STRING8”“http://schemas.microsoft.com/mapi/proptag/0x003D001E

    “PR_RECEIVED_BY_ENTRYID”“http://schemas.microsoft.com/mapi/proptag/0x003F0102

    “PR_RECEIVED_BY_NAME”“http://schemas.microsoft.com/mapi/proptag/0x0040001E

    "PR_SENT_REPRESENTING_ENTRYID" propertyAccessor.GetProperty("http://schemas.microsoft.com/mapi/proptag/0x00410102"

    “PR_SENT_REPRESENTING_NAME”“http://schemas.microsoft.com/mapi/proptag/0x0042001E

    "PR_REPLY_RECIPIENT_ENTRIES" "http://schemas.microsoft.com/mapi/proptag/0x004F0102"

    “PR_REPLY_RECIPIENT_NAMES”“http://schemas.microsoft.com/mapi/proptag/0x0050001E

    “PR_RECEIVED_BY_SEARCH_KEY”“http://schemas.microsoft.com/mapi/proptag/0x00510102

    “PR_SENT_REPRESENTING_ADDRTYPE”“http://schemas.microsoft.com/mapi/proptag/0x0064001E

    “PR_SENT_REPRESENTING_EMAIL_ADDRESS”“http://schemas.microsoft.com/mapi/proptag/0x0065001E

    “PR_CONVERSATION_TOPIC”“http://schemas.microsoft.com/mapi/proptag/0x0070001E

    "PR_CONVERSATION_INDEX" "http://schemas.microsoft.com/mapi/proptag/0x00710102"

    “PR_RECEIVED_BY_ADDRTYPE”“http://schemas.microsoft.com/mapi/proptag/0x0075001E

    “PR_RECEIVED_BY_EMAIL_ADDRESS”“http://schemas.microsoft.com/mapi/proptag/0x0076001E

    “PR_TRANSPORT_MESSAGE_HEADERS”“http://schemas.microsoft.com/mapi/proptag/0x007D001E

    “PR_SENDER_ENTRYID”“http://schemas.microsoft.com/mapi/proptag/0x0C190102

    “PR_SENDER_NAME”“http://schemas.microsoft.com/mapi/proptag/0x0C1A001E

    “PR_SENDER_SEARCH_KEY”“http://schemas.microsoft.com/mapi/proptag/0x0C1D0102

    "PR_SENDER_ADDRTYPE" "http://schemas.microsoft.com/mapi/proptag/0x0C1E001E"

    “PR_SENDER_EMAIL_ADDRESS”“http://schemas.microsoft.com/mapi/proptag/0x0C1F001E

    "PR_DISPLAY_BCC" "http://schemas.microsoft.com/mapi/proptag/0x0E02001E"

    "PR_DISPLAY_CC" "http://schemas.microsoft.com/mapi/proptag/0x0E03001E"

    "PR_DISPLAY_TO" "http://schemas.microsoft.com/mapi/proptag/0x0E04001E"

    “PR_MESSAGE_DELIVERY_TIME”http://schemas.microsoft.com/mapi/proptag/0x0E060040

    “PR_MESSAGE_FLAGS”“http://schemas.microsoft.com/mapi/proptag/0x0E070003

    "PR_MESSAGE_SIZE" "http://schemas.microsoft.com/mapi/proptag/0x0E080003"

    “PR_PARENT_ENTRYID”“http://schemas.microsoft.com/mapi/proptag/0x0E090102

    “PR_MESSAGE_RECIPIENTS”“http://schemas.microsoft.com/mapi/proptag/0x0E12000D

    “PR_MESSAGE_ATTACHMENTS”“http://schemas.microsoft.com/mapi/proptag/0x0E13000D

    "PR_HASATTACH" "http://schemas.microsoft.com/mapi/proptag/0x0E1B000B"

    “PR_NORMALIZED_SUBJECT”“http://schemas.microsoft.com/mapi/proptag/0x0E1D001E

    “PR_RTF_IN_SYNC”“http://schemas.microsoft.com/mapi/proptag/0x0E1F000B

    “PR_PRIMARY_SEND_ACCT”“http://schemas.microsoft.com/mapi/proptag/0x0E28001E

    “PR_NEXT_SEND_ACCT”“http://schemas.microsoft.com/mapi/proptag/0x0E29001E

    "PR_ACCESS" "http://schemas.microsoft.com/mapi/proptag/0x0FF40003"

    "PR_ACCESS_LEVEL" "http://schemas.microsoft.com/mapi/proptag/0x0FF70003"

    “PR_MAPPING_SIGNATURE”“http://schemas.microsoft.com/mapi/proptag/0x0FF80102

    "PR_RECORD_KEY" "http://schemas.microsoft.com/mapi/proptag/0x0FF90102"

    “PR_STORE_RECORD_KEY”“http://schemas.microsoft.com/mapi/proptag/0x0FFA0102

    “PR_STORE_ENTRYID”“http://schemas.microsoft.com/mapi/proptag/0x0FFB0102

    "PR_OBJECT_TYPE" "http://schemas.microsoft.com/mapi/proptag/0x0FFE0003"

    “PR_ENTRYID”“http://schemas.microsoft.com/mapi/proptag/0x0FFF0102

    “PR_BODY”“http://schemas.microsoft.com/mapi/proptag/0x1000001E

    “PR_RTF_COMPRESSED”“http://schemas.microsoft.com/mapi/proptag/0x10090102

    "PR_HTML" "http://schemas.microsoft.com/mapi/proptag/0x10130102"

    “PR_INTERNET_MESSAGE_ID”“http://schemas.microsoft.com/mapi/proptag/0x1035001E

    “PR_LIST_UNSUBSCRIBE”“http://schemas.microsoft.com/mapi/proptag/0x1045001E

    “不适用”“http://schemas.microsoft.com/mapi/proptag/0x1046001E

    "PR_CREATION_TIME" "http://schemas.microsoft.com/mapi/proptag/0x30070040"

    “PR_LAST_MODIFICATION_TIME”“http://schemas.microsoft.com/mapi/proptag/0x30080040

    "PR_SEARCH_KEY" "http://schemas.microsoft.com/mapi/proptag/0x300B0102"

    “PR_STORE_SUPPORT_MASK”“http://schemas.microsoft.com/mapi/proptag/0x340D0003

    “不适用”“http://schemas.microsoft.com/mapi/proptag/0x340F0003

    "PR_MDB_PROVIDER" "http://schemas.microsoft.com/mapi/proptag/0x34140102"

    "PR_INTERNET_CPID" "http://schemas.microsoft.com/mapi/proptag/0x3FDE0003"

    “副作用”“http://schemas.microsoft.com/mapi/proptag/0x80050003

    "InetAcctID" "http://schemas.microsoft.com/mapi/proptag/0x802A001E"

    "InetAcctName" "http://schemas.microsoft.com/mapi/proptag/0x804F001E"

    "RemoteEID" "http://schemas.microsoft.com/mapi/proptag/0x80660102"

    "x-rcpt-to" "http://schemas.microsoft.com/mapi/proptag/0x80AD001E"

    【讨论】:

    • 哦,哇!我刚刚找到了另外两个带有架构的页面,但是这个列表似乎是完整的,并且具有更好的格式,并且绝对应该保留在 SO 上供其他人查找!你能告诉我如何设置日期属性吗?当我使用 CSharp 的 DateTime 或将其转换为字符串时,它似乎崩溃了。 item.PropertyAccessor.SetProperty("http://schemas.microsoft.com/mapi/proptag/0x0E060040", DateTime.Now);
    • 或许,这会有所帮助:stackoverflow.com/questions/33629920/…
    • 哇,对于一些应该开箱即用的解决方法似乎很麻烦
    【解决方案2】:

    查看带有OutlookSpy 的属性的邮件 - 选择邮件,单击 OutlookSpy 功能区上的 IMessage 按钮,选择属性,查看 DASL 编辑 bx。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2012-08-26
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2014-11-16
      • 1970-01-01
      相关资源
      最近更新 更多