Search code examples
javascriptjqueryms-officeoffice365office365-apps

Outlook.com App - How to create event with HTML body pre-populated


I'm creating a Mail App for Outlook.com.

I want to create a new event from my read app and pre-populate the body with some html.

I'm using the Mailbox.displayNewAppointmentForm() method, and it opens a new event successfully. However, the body content always shows up as plain text, even though I'm sending an HTML string. (eg."<!Doctype html><html>...</html>")

The body parameter is described in the documentation as:

"The body of the appointment message. The body content is limited to a maximum size of 32 KB."

It doesn't say that it must be a string, or that plaintext is the only thing allowed. Can I create some sort of body object in which I specify the type? How would I do that?

I've tried sending some other (made up) parameters - CoercionType, and/or BodyType, but nothing seems to be working.

Any ideas? Any help is appreciated. Thanks!


Solution

  • The body parameter is indeed interpreted as plain text. There currently is no way to coerce it to HTML. I passed this along to the engineering team, hopefully this is something we can improve in the future.