Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

How do I P/Invoke a DLL that I wrote in C, that is not in the path? I need to do the following steps in C#:

- Query the registry to find the location of unmanaged DLL

- Somehow communicate the location of the DLL to P/Invoke

- Then utilize the member functions of the unmanaged DLL

 

If I put my unmanaged DLL in system32, P/Invoke finds it fine and I can utilize its functionality however this is not an option on the customer system. The unmanaged DLL gets installed to a Program Files directory that the customer can change, and its not the same directory where my C# assembly is located.

 

Thanks!

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...