Error: The assembly "c:\MyAssembly.dll" could not be converted to a type library

Justin picture Justin · Aug 23, 2010 · Viewed 8.4k times · Source

I'm trying to build my project and I've suddenly started getting the following error when the project builds and the "Register for COM interop" property is ticked.

The assembly "c:\MyAssembly.dll" could not be converted to a type library. Type library exporter encountered an error while processing 'SomeType, MyAssembly'. Error: Referenced type is defined in managed component, which is imported from a type library that could not be loaded (type: 'OtherType'; component: 'c:\OtherAssembly.dll').

Nobody else on the team gets this error, its just me! Clearly I have done something odd to my machine, however the brute force approach of completely removing / deleting and re-adding everything I could think of made no difference, and so I am resigned to actually understanding this error (what a drag!)

So:

  • What does this error actually mean
  • Where should I look next for additional / more specific diagnostic information on what is wrong?

Answer

Rommel Manalo picture Rommel Manalo · Mar 8, 2012

I had this problem to. I just did the same, gactutil /u (for the uninstall) and gacutil /i (for the install) and the problem was solved