Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The Office.context.officeTheme property is undefined in Outlook 2016 #43

Closed
eblancperso opened this issue Dec 20, 2017 · 1 comment
Closed
Labels
Area: Outlook Issue related to Outlook add-ins

Comments

@eblancperso
Copy link

eblancperso commented Dec 20, 2017

The property Office.context.officeTheme is undefined when used in the Outlook application: Official documentation. In Word, Excel and PowerPoint, the property is defined and I can access its children properties (bodyBackgroundColor, controlForegroundColor, etc...). I tried with both latest (1.1.0.13) and previous (1.1.0.12) versions of Office.JS but it doesn't work.

Expected Behavior

The officeTheme property inside the context provides bodyBackgroundColor, controlForegroundColor, etc... in all applications

Current Behavior

The officeTheme property inside the context is undefined in Outlook

Steps to Reproduce, or Live Example

Office.initialize = function (reason) {
    $(document).ready(function () {

        // The "Office" object and its "context" property are valid but the "officeTheme" property is undefined.
        // This works in Word, Excel and PowerPoint but not in Outlook.
        if (!Office.context.officeTheme) {
            console.log("Office theme not loaded");
        }
    });
}

Your Environment

PC desktop
Outlook 2016
Version 1711 Build. 8730.2127

@hongbo-miao hongbo-miao added the Area: Outlook Issue related to Outlook add-ins label Jan 11, 2018
@dmahugh
Copy link
Contributor

dmahugh commented Jun 19, 2019

Closing this old issue, which should be fixed in current builds. Apologies for the delayed response, and please let us know if the problem persists.

@dmahugh dmahugh closed this as completed Jun 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: Outlook Issue related to Outlook add-ins
Projects
None yet
Development

No branches or pull requests

3 participants