Top "Dllimport" questions

Use this tag for questions about importing functions, data or objects from DLLs (Dynamic-link libraries).

DllNotFoundException with HRESULT 0x8007007E when loading 64-bit dll

I downloaded zlib and compiled the library as both Windows 32-bit and Windows 64-bit dll. I now have zlibwapi.dll …

c# visual-studio-2008 pinvoke dllimport dllnotfoundexception
How to use a class in DLL?

Can I put a class inside a DLL? The class i wrote is this: class SDLConsole { public: SDLConsole(); ~SDLConsole(){}; void …

c++ class dllimport dllexport
Calling C DLL from C#

I am trying to call a C DLL from C#, but I'm not having any joy. The documentation for the …

c# c dll pinvoke dllimport
Where to put DllImport?

static class Class { public static void methodRequiringStuffFromKernel32() { // code here... } } Where do I put [DllImport("Kernel32.dll")] here?

c# dllimport
DllImport vs Declare in VB.NET

I notice in the MSDN documentation that there are multiple ways to declare a reference to a function in an …

vb.net dllimport declare
What's the equivalent of WORD in C#?

I'm trying to access an unmanaged library and am lucky to have access to a comprehensive guide to the API. …

c# c++ word unmanaged dllimport
Exporting global variables from DLL

I'm trying to export a global variable from a DLL. Foo.h class Foo { public: Foo() {} }; #ifdef PROJECT_EXPORTS #define …

c++ visual-studio dll dllimport
Unload a DLL loaded using DllImport

How do I unload a DLL which has been loaded using DllImport in C#?

c# dllimport
Passing byte array between C++ and C# ByRef raises AccessViolationException

I am trying to create a Win32 DLL exposes some functions which are called in C# as follows __declspec(dllexport) …

c# c++ pinvoke dllimport
How do I DllExport a C++ Class for use in a C# Application

I have created a C++ Dll project which contains a class "myCppClass" and tried to Dll export it using the …

c# c++ dll dllimport dllexport