简体   繁体   English

加载项不在办公室中加载

[英]Add-in is not loading in office

I have a word com add-in that has been working fine previously but due to some reasons, I reinstalled my Windows-OS, MS-office and add-in software right after that It is showing in inactive add-in category. 我有一个com加载项一词,该加载项以前一直可以正常运行,但是由于某些原因,我在此之后重新安装了Windows-OS,MS-office和加载项软件。它显示为非活动加载项类别。 but the load behavior is "load at startup". 但是加载行为是“启动时加载”。

unable to find the exact reason. 无法找到确切原因。 please help me and tell me how to debug this and know the root cause of this 请帮助我,告诉我如何调试它,并了解其根本原因

There are multiple reasons why add-ins are disabled by host applications... 宿主应用程序禁用加载项的原因有多种...

First of all, I'd recommend checking all the required prerequsites on the target machine. 首先,我建议检查目标计算机上所有必需的先决条件。 Make sure that al of them were installed correctly before running the host application with your add-in registered. 在注册了外接程序的情况下运行主机应用程序之前,请确保已正确安装其中的所有程序。

Microsoft Office applications can disable VSTO Add-ins that behave unexpectedly. Microsoft Office应用程序可以禁用行为异常的VSTO加载项。 If an application does not load your VSTO Add-in, the application might have hard disabled or soft disabled your VSTO Add-in. 如果应用程序未加载VSTO加载项,则该应用程序可能已硬禁用或软禁用了VSTO加载项。

Hard disabling can occur when an VSTO Add-in causes the application to close unexpectedly. 当VSTO加载项导致应用程序意外关闭时,可能会发生硬禁用。 It might also occur on your development computer if you stop the debugger while the Startup event handler in your VSTO Add-in is executing. 如果在执行VSTO加载项中的Startup事件处理程序时停止调试器,则它也可能在开发计算机上发生。

Soft disabling can occur when a VSTO Add-in produces an error that does not cause the application to unexpectedly close. 当VSTO加载项产生不会导致应用程序意外关闭的错误时,可能会发生软禁用。 For example, an application might soft disable a VSTO Add-in if it throws an unhandled exception while the Startup event handler is executing. 例如,如果在启动事件处理程序执行期间引发未处理的异常,则应用程序可能会软禁用VSTO加载项。

When you re-enable a soft-disabled VSTO Add-in, the application immediately attempts to load the VSTO Add-in. 当您重新启用软禁用的VSTO加载项时,应用程序将立即尝试加载VSTO加载项。 If the problem that initially caused the application to soft disable the VSTO Add-in has not been fixed, the application will soft disable the VSTO Add-in again. 如果最初导致应用程序软禁用VSTO加载项的问题尚未解决,则应用程序将再次软禁用VSTO加载项。 Read more about that in the How to: Re-enable a VSTO Add-in That Has Been Disabled article. 在“ 如何:重新启用已禁用的VSTO加载项”一文中了解有关此内容的更多信息。

You may also find the following articles helpful: 您可能还会发现以下文章有所帮助:

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM