所有Word 2016添加程序都错误地自动开放,不尊重office.AutoShowTaskPanewithDocument&quots&quots Taskpane可见性“ 1”

发布于 2025-02-01 07:52:25 字数 771 浏览 3 评论 0原文

我已经观察到O365与文档 on office.js taskpanes上的“ auto Open”行为,但W2016不是,所以我想知道这是否是一个错误,还是是否有其他说明应该参考。

我已经用我的加载项,新创建的Word加载项(模板)和商店中的Wikipedia加载项对此进行了测试。

即使office.autoshowtaskpanewithdocument不存在或设置为false时,即使在Office.js任务pan开放时,保存在W2016中的Word文档也将自动开放。这是因为可见性设置为word/webextensions/taskpanes.xml中的“ 1”(而O365中的设置为“ 0”)。对于未安装附加组件的用户,任何带有加载项打开的文档(即使没有自动打开或设置为false的文档)都会显示空白。

  1. 这是预期的行为,如果是这样,则我如何通过编程(通过Office.js,而不是通过修改RAW XML)确保加载程序不会自动打开W2016上创建的文档?
  2. 有没有办法可以编程为加载项设置“可见性”设置?

提前致谢!

I've observed that O365 is consistent with the documentation on "Auto Open" behavior for Office.js taskpanes, but W2016 is not, so I'm wondering if this is a bug or if there's alternate instructions I should refer to.

I've tested this with my add-in, a newly created word add-in (template), and the Wikipedia add-in on the store.

Word documents saved in W2016 while an Office.js taskpane is open will auto-open, even if Office.AutoShowTaskpaneWithDocument is absent or set to false. This is because visibility is set to "1" in word/webextensions/taskpanes.xml (whereas its set to "0" in O365). For users who don't have the add-in installed, any document saved with the add-in open (even those with auto open absent or set to false) will show a blank add in.

  1. Is this expected behavior, and if so, how can I programmatically (via Office.js, not by modifying the raw xml) ensure the add-in does not auto-open for docs created on W2016?
  2. Is there a way to programmatically set the "visibility" setting for the add-in?

Thanks in advance!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文