0

我正在开发一个 Outlook 加载项,目的是创建一个具有不同属性的约会。

是否可以使用邮箱 API 修改提醒字段的值?我在文档( https://dev.outlook.com/reference/add-ins/)中找不到这样做的方法。提醒栏

4

3 回答 3

0

截至今天(要求集 1.3)我认为 Office.js 中没有一种方法可以让您获取或设置约会的提醒字段。其他人已经提到您可以尝试使用 EWS 调用来执行该操作。

于 2016-05-09T21:54:17.957 回答
0

当 Outlook 加载项的 Office.js api 无法使用某些内容时,您可以尝试使用 Exchange Web 服务 (EWS) 来执行操作

看看这个先前的答案

这个答案中,我为两者(客户端或服务器端方法)提供了代码片段。

于 2016-04-27T17:11:31.800 回答
0

您可以使用UpdateItem EWS 操作使用mailbox.makeEwsRequestAsync方法设置标志和提醒字段:

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"               xmlns:m="http://schemas.microsoft.com/exchange/services/2006/messages"               xmlns:xsd="http://www.w3.org/2001/XMLSchema"               xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"               xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types">
  <soap:Header>
    <RequestServerVersion Version="Exchange2013" xmlns="http://schemas.microsoft.com/exchange/services/2006/types" soap:mustUnderstand="0" />
  </soap:Header>
  <soap:Body>
    <m:UpdateItem MessageDisposition="SaveOnly" ConflictResolution="AlwaysOverwrite">
      <m:ItemChanges>
        <t:ItemChange>
          <t:ItemId Id="AAMkAGUzNmEzYTBmLTI1NDItNGE0My1iZDk5LWFkMDgxODI3YWNlOQBGAAAAAACK2VEhi72QSaw+u0XV7xUHBwCMotTyA3QkQ7TPAmcrRt4FAAAALwVDAAAuH/1UA8tzTYD5jbYriaIUAAJEgGbPAAA=" />
          <t:Updates>
            <t:SetItemField>
              <t:FieldURI FieldURI="item:Flag" />
              <t:Message>
                <t:Flag>
                  <t:FlagStatus>Flagged</t:FlagStatus>
                  <t:StartDate>2016-02-24T00:00:00.000Z</t:StartDate>
                  <t:DueDate>2016-02-24T00:00:00.000Z</t:DueDate>
                </t:Flag>
              </t:Message>
            </t:SetItemField>
            <t:SetItemField>
              <t:FieldURI FieldURI="item:ReminderDueBy" />
              <t:Message>
                <t:ReminderDueBy>2016-02-24T15:00:00.000Z</t:ReminderDueBy>
              </t:Message>
            </t:SetItemField>
            <t:SetItemField>
              <t:FieldURI FieldURI="item:ReminderIsSet" />
              <t:Message>
                <t:ReminderIsSet>true</t:ReminderIsSet>
              </t:Message>
            </t:SetItemField>
            <t:SetItemField>
              <t:FieldURI FieldURI="item:ReminderMinutesBeforeStart" />
              <t:Message>
                <t:ReminderMinutesBeforeStart>0</t:ReminderMinutesBeforeStart>
              </t:Message>
            </t:SetItemField>
          </t:Updates>
        </t:ItemChange>
      </m:ItemChanges>
    </m:UpdateItem>
  </soap:Body>
</soap:Envelope>

于 2016-04-29T01:04:22.780 回答