Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
1.1k views
in Technique[技术] by (71.8m points)

outlook - Office 365 Manifest for command-only Add-In

I have an add-in that just contains two ExecuteFunction commands. In the generated manifest file from visual studio it contains the xml like:

<FormSettings>
    <Form xsi:type="ItemRead">
        <DesktopSettings>
            <SourceLocation DefaultValue="https://localhost:44351/MessageRead.html"/>
            <!--If you opt to include RequestedHeight, it must be between 32px to 450px, inclusive.-->
            <RequestedHeight>250</RequestedHeight>
        </DesktopSettings>
    </Form>
</FormSettings>

Since I don't have any UI in a task pane, why does it require this xml, and what would be the best practice here for my command-only add-in. Thanks.

question from:https://stackoverflow.com/questions/65890845/office-365-manifest-for-command-only-add-in

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

This XML exists for compatibility with older Outlook clients and is required by the manifest schema.

As a best practice, since your add-in only uses add-in commands, set the minimum requirement set in the manifest to at least 1.3, so the manifest and this URL won't be used by clients that don't support add-in commands.

<Requirements>
  <Sets>
    <Set Name="Mailbox" MinVersion="1.3" />
  </Sets>
</Requirements>

Technically, this SourceLocation URL still appears in the payload of an identity token, so I would suggest setting it to a URL that's unique to your add-in.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...