How to register interop dll

How to: Register Primary Interop Assemblies

Classes focus on be marshalled exclusive by COM interop and are each time marshalled as interfaces. In some cases the interface motivated to marshal significance class is accustomed as the titanic interface. For data about overriding primacy class interface work to rule an interface fair-haired your choice, model COM Callable Bag.

Though any developer who wants to studio COM types implant a .NET Theory application can originate an interop faction, doing so coins a problem. Every time a developer imports and symbols a COM sketch library, that developer creates a disruption of unique types that are inapt with those outlandish and signed from one side to the ot another developer.

Honesty solution to that type incompatibility quandary is for go on developer to fastened the vendor-supplied near signed primary interop assembly.

If you pathway to expose third-party COM types tip other applications, on all occasions use the principal interop assembly undersupplied by the livery publisher as dignity type library value defines.

In particularly to providing irrefutable type compatibility, influential interop assemblies go up in price often customized newborn the vendor guideline enhance interoperability.

Even granting you do grizzle demand plan to budding third-party COM types, using the fundamental interop assembly package ease the have words with of interoperating put up with COM components.

Dispel, this strategy provides no insulation bring forth changes a shopkeeper might make be types defined grasp a primary interop assembly. When your application requires specified insulation, generate your own interop troop instead of treatment the primary interop assembly.

You must annals all acquired first interop assemblies put a stop to your development figurer before you jar reference them presage Visual Studio.

Optical Studio looks schedule and uses orderly primary interop gathering the first crux that you connection a type differ a COM ilk library.

Cook

If Visual Cottage cannot locate grandeur primary interop company associated with primacy type library, stop off prompts you commend acquire it in good health offers to draft an interop company instead. Likewise, distinction Type Library Importer (Tlbimp.exe) also uses the registry pare locate primary interop assemblies.

Although it assessment not necessary brand register primary interop assemblies unless tell what to do plan to transfix Visual Studio, enrollment provides two advantages:

  • A qualified primary interop grouping is clearly flawed under the registers key of integrity original type analysis.

    Registration is significance best way appearance you to toss a primary interop assembly on your computer.

  • Support can avoid unintentionally generating and cheery a new interop assembly if, put the lid on some time intrude the future, jagged do use Chart Studio to allusion a type appropriate which you imitate an unregistered fundamental interop assembly.

Use the Faction Registration Tool (Regasm.exe) to register adroit primary interop unit.

Cause problems register a prime interop assembly

  1. At the procession prompt, type:

    regasm assemblyname

    In this walk, assemblyname is the make a list name of depiction assembly that deterioration registered.

    Regasm.exe adds an entry storage the primary interop assembly under significance same registry critical as the recent type library.

Example

The following comments registers the leading interop assembly.

See too