Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

missing Embed Interop Type property

In one C# project, I get the following warning:

warning CS1762: A reference was created to embedded interop assembly 'Interop.SomeLibrary.dll' because of an indirect reference to that assembly created by assembly 'ALibraryOfMine.dll'. Consider changing the 'Embed Interop Types' property on either assembly.

However, in the C# project that gives this warning, I do not see an Embed Interop Types property on the COM library reference Properties. That's in VS 2010. In the VS 2008 ALibraryOfMine project, the same COM library also does not have an Embed Interop Types property. How can I get rid of this warning? I've been getting an "The located assembly's manifest definition does not match the assembly reference" error and I'm worried maybe differing versions of a COM library is behind it, so I wanted to eliminate COM-related errors.

like image 282
Sarah Vessels Avatar asked Nov 03 '10 18:11

Sarah Vessels


People also ask

What is embed interop types?

Type embedding is frequently used with COM interop, such as an application that uses automation objects from Microsoft Office. Embedding type information enables the same build of a program to work with different versions of Microsoft Office on different computers.


2 Answers

You need to go to the Dll in the References, Right Click and Properites. It is there, not on the properties of your project

like image 187
Traci Avatar answered Oct 12 '22 03:10

Traci


I had a similar warning once - i think this can help you; http://msdn.microsoft.com/en-us/library/ff183282.aspx.

like image 23
HuseyinUslu Avatar answered Oct 12 '22 02:10

HuseyinUslu