Function Reference


_WinAPI_GetFinalPathNameByHandle

Retrieves the final path of the specified file

#include <WinAPIFiles.au3>
_WinAPI_GetFinalPathNameByHandle ( $hFile )

Parameters

$hFile Handle to a file or directory whose path is to be retrieved.

Return Value

Success: The path of the file.
Failure: Empty string and sets the @error flag to non-zero, @extended flag may contain the NTSTATUS error code.

See Also

Search ZwQueryInformationFile in MSDN Library.

Example

#include <WinAPIFiles.au3>
#include <WinAPIHObj.au3>

Local $hFile = _WinAPI_CreateFile(@ScriptFullPath, 2, 0, 6)

ConsoleWrite(_WinAPI_GetFinalPathNameByHandle($hFile) & @CRLF)

_WinAPI_CloseHandle($hFile)