开发者

Word AddIn Doesn't Load, But When I Change Visual Studio's "Solution Configuration" from Debug to Release It Loads

I apologize if this is a duplicate but I couldn't find any solutions that worked or any symptoms identical to mine.

I have a VSTO Word AddIn I've been developing for awhile. I've never changed Visual Studio's (2010) "Solution Configuration" before; I've just left it as Debug. But today my AddIn has stopped loading in Word. It appears in the list of Word COM addins (the list you get when you open word, go to Word Options \ AddIns), but the checkmark is off, and when I turn the checkmark on and return to that list of COM addins, it's off again. Also the message for the AddIn in Word's list of AddIns is just "Unloaded"; not anything like "Unloaded: an error occurred while..." Cleaning and rebuilding doesn't help. Deleting its registry node in HKCU\Software\Microsoft\Office\Word\AddIns doesn't help. Removing the AddIn from Word's list of AddIns doesn't help. I'm stumped.

The only clues I have as to what is going on are: 1) there is no output from my Build/Run when I am in Debug configuration. The Output window of Visual Studio is just blank. 2) When I switch to Release configuration in Visual Studio, my build/run now results in output in the output window and the addin loads properly in wo开发者_JAVA百科rd. I feel like this information might help someone more knowledgeable than I about Word/VSTO/Visual Studio.

Help? Thank you.


You can also fix this by File | Options | Add-ins | Then in Manage combo box select disabled items then click Go.. button.

A dialog will popup with your add-in listed and you can re-enable it.

Enjoy!


I ended up fixing this by duplicating the "Debug" solution configuration. Now I have "Debug2" and it seems to work just fine.


Make sure that all the icons you use have been added to the project. It just happened to me: an icon is added to the resources file (.resx) but not to the project (.csproj). Run the solution: no add-in, no error message.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜