[Sample of May 3rd] C# app dynamically loads a native DLL

  Sample Downloads: http://code.msdn.microsoft.com/CSLoadLibrary-4f25687f Today’s sample demonstrates dynamically load a native DLL by P/Invoking LoadLibrary, and invoke its exported functions. You can find more code samples that demonstrate the most typical programming scenarios by using Microsoft All-In-One Code Framework Sample Browser or Sample Browser Visual Studio extension. They give you the flexibility to search samples,…


[Sample of May 2nd] C#/VB P/Invokes a native DLL

  Sample Downloads C#: http://code.msdn.microsoft.com/CSPInvokeDll-b05779d0 VB: http://code.msdn.microsoft.com/VBPInvokeDll-e220099a Today’s sample demonstrates how to P/Invoke native DLLs from C# and VB.NET.  You can find more code samples that demonstrate the most typical programming scenarios by using Microsoft All-In-One Code Framework Sample Browser or Sample Browser Visual Studio extension. They give you the flexibility to search samples, download…


All-In-One Interop and Fusion Code Samples

All-In-One Interop and Fusion Code Samples  Introduction Download Interop and Fusion code samples Request Interop and Fusion code samples Introduction The All-In-One Interop and Fusion code samples demonstrate the typical programming topics about .NET – native interop, COM interop, fusion, .NET Reflection, etc. These topics are either frequently asked in MSDN forums and Microsoft Support, or…


Invoke Native C++ DLL from .NET Code

Jialiang Ge has just finished a summary of solutions to invoke native C++ DLL from .NET code. Solution 1. (Explicit) P/InvokeSolution 2. Dynamic P/InvokeSolution 3. Implicit P/Invoke (Use a C++/CLI wrapper)Solution 4. Convert C++ DLL to a COM server, and call it from .NET code through .NET-COM interop The detailed and working code samples are…


Invoke .NET Assembly from Native C++ Code

Jialiang Ge has just finished a summary of solutions to invoke .NET assembly from native C++ code. Solution 1. Use a C++/CLI wrapperSolution 2. Host CLRSolution 3. Convert .NET assembly to a COM server, and call it from C++ through .NET-COM interop The detailed and working code samples are attached to the above article. If you…