GetModuleFileName function Null safety kernel32

int GetModuleFileName(
  1. int hModule,
  2. Pointer<Utf16> lpFilename,
  3. int nSize
)

Retrieves the fully qualified path for the file that contains the specified module. The module must have been loaded by the current process.

DWORD GetModuleFileNameW(
  HMODULE hModule,
  LPWSTR  lpFilename,
  DWORD   nSize
);

Implementation

int GetModuleFileName(int hModule, Pointer<Utf16> lpFilename, int nSize) =>
    _GetModuleFileName(hModule, lpFilename, nSize);