StormLib API Reference

SFileGetFileName

Description

bool WINAPI SFileGetFileName(
  HANDLE hFile,                     // File handle
  char * szFileName                 // Pointer to buffer that receives file name
);

Function SFileGetFileName retrieves the name of an open file.

Parameters

hFile
[in] Handle to an open file. The file handle must have been created by SFileOpenFileEx.
szFileName
[out] Receives the file name. The buffer must be at least MAX_PATH characters long.

Return Value

When the function succeeds, it returns true and buffer pointed by szFileName contains name of the file. On an error, the function returns false and GetLastError returns an error code.

Remarks

This function doesn't support local files open by SFileOpenFileEx. If the file has been open with a pseudo file name, the function returns this name. If the file name is not known and the extension can be determined by file content, the returned pseudo file name also contains the proper extension. The pseudo name can be passed to SFileOpenFileEx.

Availability in Storm.dll

Available in Storm.dll No
Ordinal number in Storm.dll 1.00 N/A
Ordinal number in Storm.dll 1.09 N/A