Category Archive for: Interoperability

Freeing Memory

With .NET, memory is released by the garbage collector. This is completely different with COM. COM  relies on reference counts. The interface !Unknown, which is the interface that is required to be implemented by every COM object,offers three methods. Two of these methods are related to reference counts. The method AddRef ( ) must be called…

Read More →

Metadata

With COM, all information about the component is stored inside the type library. The type library includes information such as names and IDs of interfaces, methods, and arguments. With .NET, all this information can be found inside the assembly itself, as you saw in Chapter 13, “Reflection,” and Chapter 17, “Assemblies.” The problem with COM is that the…

Read More →

.NET and COM

COM is the predecessor technology to .NET. COM defules a component model where components can be written in different programming languages. A component written with C++ can be used from a Visual Basic client. Components can also be used locally inside it process, across processes, or across the network. Does this sound familiar? Of course, .NET has similar…

Read More →

Interoperability

If you have Windows programs written prior to .NET, you probably don’t have the time and resources to rewrite everything for .NET.Sometimes rewriting code is useful for refactoring or rethinking the application architecture. A rewrite can also help with productivity in the long-term, when adding new features is easier to do with the new technology. However, there should…

Read More →

Back to Top