Skip to content

Latest commit

 

History

History
63 lines (43 loc) · 1.43 KB

GetMappedFileName.md

File metadata and controls

63 lines (43 loc) · 1.43 KB

Home

Function name : GetMappedFileName

Group: File Mapping - Library: kernel32


The GetMappedFileName function checks if the specified address is within a memory-mapped file in the address space of the specified process. If so, the function returns the name of the memory-mapped file.


Code examples:

Using File Mapping for enumerating files opened by Visual FoxPro

Declaration:

DWORD GetMappedFileName(
  HANDLE hProcess,
  LPVOID lpv,
  LPTSTR lpFilename,
  DWORD nSize
);
  

FoxPro declaration:

DECLARE INTEGER GetMappedFileName IN psapi;
	INTEGER  hProcess,;
	INTEGER  lpv,;
	STRING @ lpFilename,;
	INTEGER  nSize  

Parameters:

hProcess [in] Handle to the process.

lpv [in] Address to be verified.

lpFilename [out] Pointer to the buffer that receives the name of the memory-mapped file to which the address specified by lpv belongs.

nSize [in] Size of the lpFilename buffer, in characters.


Return value:

If the function succeeds, the return value specifies the length of the string copied to the buffer, in characters.


Comments:

See also: EnumProcesses, GetCurrentProcess.