getmodulefilename (coredll)
Last changed: Joseph Cooney-123.243.157.225

.
Summary

C# Signature:

[DllImport("coredll.dll", SetLastError=true)]
static extern int GetModuleFileNameEx(IntPtr hProcess, IntPtr hModule, StringBuilder lpFilename, int nSize);

C# Signature:

[DllImport("Kernel32.dll", CharSet = CharSet.Unicode, SetLastError = true)]
internal static extern bool GetModuleHandleEx(UInt32 dwFlags, string lpModuleName, out IntPtr phModule);

VB Signature:

Declare Function GetModuleFileNameEx Lib "coredll.dll" (ByVal hProcess As IntPtr, ByVal hModule As IntPtr, ByVal lpFileName As System.Text.StringBuilder, ByVal nSize As Int32) As Int32

VB Signature:

<DllImport("Kernel32.dll", CharSet:=CharSet.Unicode, SetLastError:=True)>
Friend Shared Function GetModuleHandleEx(ByVal dwFlags As UInt32, ByVal lpModuleName As String, ByRef phModule As IntPtr) As Boolean
End Function

User-Defined Types:

None.

Alternative Managed API:

Do you know one? Please contribute it!

Notes:

None.

Tips & Tricks:

Please add some!

Sample Code:

Please add some!

Documentation