Appointment.displayReplyForm method (JavaScript API for Office v1.1)

JavaScript API for Office v1.1

Displays a reply form that includes only the organizer of the selected appointment item.

Last modified: June 12, 2014

Applicable Outlook modes

Read

Available in requirement sets

Mailbox

Office.context.mailbox.item.displayReplyForm(htmlBody)

htmlBody

A string that contains text and HTML and that represents the body of the reply form. The string is limited to 32 KB.

Use this method only if the appointment is a meeting that involves an organizer and one or more attendees. Calendar items that do not involve attendees do not support replies.

In Outlook Web App, the reply form is displayed as a pop-out form in the 3-column view and a pop-up form in the 2- or 1-column view.

If htmlBody exceeds the 32-KB limit, displayReplyForm throws an exception.

The following code example in JavaScript obtains the selected item, checks if the item is an appointment, and displays a reply form to the organizer.

var myOm;
var myItem;

// Initialize runtime.
// The initialize function is required for all apps.
Office.initialize = function () {
    myOm = Office.context.mailbox;
    // Get the selected item.
    myItem = myOm.item;

    // Checks for the DOM to load using the jQuery ready function.
    $(document).ready(function () {
        // After the DOM is loaded, can display content in the app UI.
        displayReply();
    });
}

function displayReply()
{
    // Display a reply form to the organizer only if 
    // the selected item is an appointment.
    if (myitem.itemType == Office.MailboxEnums.ItemType.Appointment)
    {
        myItem.displayReplyForm
        ("<html><head><head><body>This is the body of the appointment reply.</body></html>");
    }
}

App types

Mail app

Supported clients

Outlook 2013, Outlook 2013 SP1, Outlook 2013 RT, Outlook Web App, and OWA for Devices

Library

Office.js

Namespace

Office

Reference

displayReplyAllForm method (Appointment object)
Show:
© 2014 Microsoft