Office.MailboxEnums.OpenLocation enum
Specifies the location from which an add-in wants to access data.
Remarks
Applicable Outlook mode: Compose, Read
Important: This enum is only supported in Outlook on Android and on iOS starting in Version 4.2443.0. To learn more about APIs supported in Outlook on mobile devices, see Outlook JavaScript APIs supported in Outlook on mobile devices.
Examples
// Checks if the add-in can access data from the device's photo library.
const isOpenFromPhotoLibraryAllowed = Office.context.mailbox.getIsOpenFromLocationAllowed(Office.MailboxEnums.OpenLocation.PhotoLibrary);
if (isOpenFromPhotoLibraryAllowed) {
console.log("Access to the photo library is allowed.");
// Do something.
} else {
console.log("Access to the photo library isn't allowed.");
}
Fields
AccountDocument | A location associated with an account within an add-in. |
Camera | The device's camera. |
Local | Local storage on a device. |
OnedriveForBusiness | OneDrive for Business. Important: For OneDrive Personal, use OTHER. |
Other | Other cloud storage providers, including OneDrive Personal. |
PhotoLibrary | The device's photo library. |
SharePoint | SharePoint. Includes both SharePoint Online and SharePoint on-premises (if accessed with a Microsoft Entra ID account). |
Office Add-ins