.NET Samples - How To: Interoperability

This section includes the following samples:

VB6 Test Client Sample

TestClient Sample

PInvokeSimple Sample

StringClient Sample

VB6 Test Client Sample

This sample demonstrates how to use .NET objects from a Visual Basic 6.0 application.

Namespaces used in this sample:

System; System.Runtime.CompilerServices; System.Reflection

Classes used in this sample:

Assembly; Service; File; Version

TestClient Sample

This sample demonstrates how to use a COM object from a Visual Basic. NET or C# application.

Namespaces used in this sample:

System; System.Runtime.InteropServices

Classes used in this sample:

Console; Service; Exception; COMException; String

PInvokeSimple Sample

This sample demonstrates how to call a function exported from an unmanaged library from managed code.

Namespaces used in this sample:

System; System.Runtime.InteropServices

Classes used in this sample:

String; Import; Message; Service; MessageBox

StringClient Sample

This sample demonstrates how to marshal strings from a .NET client to a COM server.

Namespaces used in this sample:

System; System.Text; System.Runtime.InteropServices

Classes used in this sample:

Console; String; Service