首页 > 解决方案 > Outlook 插件:Office 2016 桌面客户端:SCRIPT5022:Office.js 尚未完全加载

问题描述

我正在构建一个前景插件。插件在 office online 上运行良好,但在桌面客户端 (2016) 上失败并出现错误

SCRIPT5022: Office.js has not fully loaded. Your app must call "Office.onReady()" as part of it's loading sequence (or set the "Office.initialize" function). If your app has this functionality, try reloading this page. office.debug.js (1501,33)

这很令人困惑,因为我已经尝试了以下操作并且所有工作都在线......但不是在桌面客户端中。

版本 1

Office.initialize = function () {
    $(document).ready(function () {
      run();
    });
};

版本 2

Office.onReady(function() {
    $(document).ready(function () {
        run();
    });
});

版本 3:

Office.onReady(function() {
        run();
});

由于某种原因,桌面客户端失败。

标签: outlookoffice365office-jsoffice-addins

解决方案


推荐阅读