Function Reference


_WinAPI_GetProcessFileName

Retrieves the fully-qualified path of the executable file for the specified process

#include <WinAPIProc.au3>
_WinAPI_GetProcessFileName ( [$iPID = 0] )

Parameters

$iPID [optional] The PID of the process. Default (0) is the current process.

Return Value

Success: The fully-qualified path to the file.
Failure: Sets the @error flag to non-zero.

See Also

Search GetModuleFileNameEx in MSDN Library.

Example

#include <WinAPIProc.au3>

Local $iID = ProcessExists('SciTE.exe')

If $iID Then
        ConsoleWrite(_WinAPI_GetProcessFileName($iID) & @CRLF)
EndIf