embeded interop types

2358
1
Jump to solution
08-11-2016 01:43 PM
YinghongLi
Occasional Contributor

I migrated my arcobject project from 10.3.1/VS2013 to 10.4.1/VS2015.  The biggest change was from .net version 3.5 to .net 4.5.2.  Then I saw a property for ArcObject reference which is "embedded interop types".  This property does exist in my VS2013/ArcObject project.  I got lot of errors.  I had to set this property to "false" .  By default some of the ArcObject references were set to true and some of them were false.  After I set them all to false and errors disappeared.  I'd like to know if i did correct thing to set this property to false for all the ArcObject references.

Thanks

Tags (1)
0 Kudos
1 Solution

Accepted Solutions
seria
by Esri Contributor
Esri Contributor

Setting "Embed Interop Types" to "false" in Visual Studio is the correct thing to do, and indeed, some of your errors with regard to some of your assembly references would be resolved after setting that value to false. This is a general rule of thumb when migrating ArcObjects code from an older to a newer version.

For a more detailed explanation, please view the MSDN help page on embedded Interop Types.

Type Equivalence and Embedded Interop Types

https://msdn.microsoft.com/en-us/library/dd997297(v=vs.110).aspx

View solution in original post

1 Reply
seria
by Esri Contributor
Esri Contributor

Setting "Embed Interop Types" to "false" in Visual Studio is the correct thing to do, and indeed, some of your errors with regard to some of your assembly references would be resolved after setting that value to false. This is a general rule of thumb when migrating ArcObjects code from an older to a newer version.

For a more detailed explanation, please view the MSDN help page on embedded Interop Types.

Type Equivalence and Embedded Interop Types

https://msdn.microsoft.com/en-us/library/dd997297(v=vs.110).aspx