Export (0) Print
Expand All

Time.setAsync method (JavaScript API for Office v1.1)

JavaScript API for Office v1.1

Begins an asynchronous request to set the start or end time. This method was introduced in version 1.1.

Last modified: June 26, 2014

Applicable Outlook modes

Compose

Available in requirement sets

Mailbox

Office.context.mailbox.item.[start,end].setAsync(dateTime, [options,] callback);

dateTime

A date-time object in Coordinated Universal Time (UTC). See the Remarks section for details.

options

Any optional parameters or state data passed to the method. Optional.

callback

The method to call when the start or end time is returned. Optional.

The setAsync method starts an asynchronous call to the Exchange server to set the start or end time of an appointment.

If the start.setAsync method is called, the end property will be adjusted to maintain the duration of the appointment as previously set. If the end.setAsync method is called, the duration of the appointment will be extended to the new end time.

The time must be in UTC; you can get the correct UTC time by using the Mailbox.convertToUtcClientTime method.

If you specify a callback method, the method is called with one parameter, asyncResult, which contains a code that indicates any error setting the time.

Error code

Description

InvalidEndTime

The appointment end time is before the appointment start time.

App types

Mail app

Supported clients

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

Library

Office.js

Namespace

Office

Show:
© 2014 Microsoft