首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >office.context.mailbox未定义

office.context.mailbox未定义
EN

Stack Overflow用户
提问于 2017-06-30 11:25:28
回答 1查看 1K关注 0票数 1

当我尝试在视图中打开一个弹出时。我在弹出office.context.mailbox中得到未定义的controller.But,我在controller.Please中得到了object如下所示

代码语言:javascript
复制
(function() {
    'use strict';
    angular.module('wpoffice')
        .component('externalTrack', 
            templateUrl: 'app/components/externalTrack/external-track_template.html',
            controller: ExternalTrackController,
            bindings: {}
        });
​
    /** ngInject*/
​
    function ExternalTrackController($rootScope, $scope, $timeout, appData, ngNotify,$q,trackingService) {
        var self = this;
        self.$onInit = activate;
        function activate() {
            console.log(Office)
            console.log(Office.context.mailbox);
    }
}
})();

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2017-07-01 17:30:51

您无法在对话框API启动的弹出中访问大多数函数,而且我认为如果您使用window.open,它也没有理由工作。

The messageParent function is one of only two Office APIs that can be called in the dialog box. (The other is Office.context.requirements.isSetSupported) 对话框API文档

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/44845349

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档