Office.LocalClientTime interface
Represents a date and time in the local client's time zone. Read mode only.
Remarks
Minimum permission level: read item
Applicable Outlook mode: Read
Examples
// Link to full sample: https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/outlook/90-other-item-apis/get-start-read.yaml
const time = Office.context.mailbox.item.start;
const localTime = Office.context.mailbox.convertToLocalClientTime(time);
console.log(`Appointment starts (local): ${localTime.month + 1}/${localTime.date}/${localTime.year}, ${localTime.hours}:${localTime.minutes}:${localTime.seconds}`);
Properties
| date | Integer value representing the day of the month. |
| hours | Integer value representing the hour on a 24-hour clock. |
| milliseconds | Integer value representing the milliseconds. |
| minutes | Integer value representing the minutes. |
| month | Integer value representing the month, beginning with 0 for January to 11 for December. |
| seconds | Integer value representing the seconds. |
| timezone |
Integer value representing the number of minutes difference between the local time zone and UTC. |
| year | Integer value representing the year. |
Property Details
date
Integer value representing the day of the month.
date: number;
Property Value
number
hours
Integer value representing the hour on a 24-hour clock.
hours: number;
Property Value
number
milliseconds
Integer value representing the milliseconds.
milliseconds: number;
Property Value
number
minutes
Integer value representing the minutes.
minutes: number;
Property Value
number
month
Integer value representing the month, beginning with 0 for January to 11 for December.
month: number;
Property Value
number
seconds
Integer value representing the seconds.
seconds: number;
Property Value
number
timezoneOffset
Integer value representing the number of minutes difference between the local time zone and UTC.
timezoneOffset: number;
Property Value
number
year
Integer value representing the year.
year: number;
Property Value
number