Title: VSTO Template UI doesn't appear when 2 seperate dll's are in the project
Tags: c#;user-interface;vsto
Question: I have been trying to get a VSTO template for excel to install but I can't see the VSTO ribbon buttons or task pane when I open the template after the install. At first I didn't think it was henrymorris@example.net. The project works fine in visual studio.

I followed the article here http://msdn.microsoft.com/en-us/library/ff937654.aspx &amp; as above the UI elements were not visible. I then followed the same article for a very basic template project &amp; it worked fine.

I removed all the code from the UI of my template project, recreated the install package &amp; it installed &amp; I could see the UI. I uncommented the code till i found the lines which were preventing me from seeing the UI. 
There are 2 seperate Dll's that the template uses, they are both in the references of the template project and they are both showing as being detected dependencies in the install project &amp; they are both placed in the install directory of the template. The problem is the UI doesn't appear if I use the dll's in my templates code. I just have to attempt to create an instance of one of the 2 dll's classes and the UI stops appearing.

Does anyone know why this may be happening?



Here is another answer: Probably you have not included the following - 

```using System.Runtime.InteropServices
```


{'source': 'StackExchangeDataset', 'subset': 'stackoverflow.com', 'metadata': {'AnswerCount': 1, 'CommentCount': 0, 'ContentLicense': 'CC BY-SA 3.0', 'CreationDate': '2013:00:01/23/13', 'FavoriteCount': 1.0, 'PostTypeId': 1, 'Tags': '<c#><user-interface><vsto>', 'Title': "VSTO Template UI doesn't appear when 2 seperate dll's are in the project", 'ViewCount': 77, 'id': 14481587, 'user_AboutMe': None, 'user_AccountId': 989276.0, 'user_DisplayName': 'user1007000', 'user_Reputation': 1.0, 'user_Views': 0.0, 'user_id': 1007000.0}}