1

My question is only about terminology. Does "COM Interop" refer only to using a COM component or object inside a .NET project?

What term is best used for the practice of making a .NET Assembly and designing and configuring it for use in COM applications (such as VB6 or VBA)?

HK1
  • 11,941
  • 14
  • 64
  • 99
  • It goes both ways, .NET code can interop with a COM server, *and* you can create a COM server in .NET code. Both COM interop. Best term is the name of the attribute, you make it "COM visible". – Hans Passant Apr 07 '11 at 17:43

4 Answers4

3

COM Object :

Component Object Model (COM) is a binary-interface standard for software componentry introduced by Microsoft in 1993. It is used to enable interprocess communication and dynamic object creation in a large range of programming languages. The term COM is often used in the Microsoft software development industry as an umbrella term that encompasses the OLE, OLE Automation, ActiveX, COM+ and DCOM technologies.

So a COM object isn't language dependent. It's a communication protocol.
So anything that uses this protocol is a COM Object.

You can create dlls that support COM Communication using .NET Framework.

A COM Interop is the interface .NET uses to wrap the COM Communication so you can write regular .NET code without having to mess with COM protocol and declarations. Visual Studio can create Interops when you reference COM objects to the project.

COM Interop is a technology included in the .NET CLR that enables COM objects to interact with .NET objects, and vice versa.

Daniel Hilgarth
  • 171,043
  • 40
  • 335
  • 443
Yochai Timmer
  • 48,127
  • 24
  • 147
  • 185
0

Such classes are often referred to as CCWs COM-callable wrappers.
COM Interop means both: Using COM from .Net and using .Net via COM.

Robert Giesecke
  • 4,314
  • 21
  • 22
0

COM interop is usually referred to the .NET binding assembly to a COM DLL. For example when you add a reference to a COM DLL in a .NET project and it is created.

Aliostad
  • 80,612
  • 21
  • 160
  • 208
0

From what I know, COM Interop would be using either COM from .NET or the other way around.

Now you have two options to make your .NET assembly COM Visible See this:
"Register for COM Interop" vs "Make assembly COM visible"

When you want to use a COM Library Visual Studio will use Tblimp.exe and generate a interop assembly which can be used within .NET. For the process the other way around there is Tblexp.exe

This somewhat old article covers quite a bit about COM Interop in .NET. (Note, it talks about Iterop both ways)

Do remember .NET4 has some nice new features to use COM from .NET.

Community
  • 1
  • 1
gideon
  • 19,329
  • 11
  • 72
  • 113