Platform SDK: Debugging and Error Handling |
The FindExecutableImage function locates an executable file.
To specify a callback function, use the FindExecutableImageEx function.
HANDLE FindExecutableImage( PSTR FileName, PSTR SymbolPath, PSTR ImageFilePath );
If the function succeeds, the return value is an open handle to the executable file.
If the function fails, the return value is NULL. To retrieve extended error information, call GetLastError.
The FindExecutableImage function is provided so executable files can be located in several different directories through a single function call. The SymbolPath parameter can contain multiple paths, with each separated by a semicolon (;). When multiple paths are specified, the function searches each directory tree for the executable file. When the file is located, the search stops. Thus, be sure to specify SymbolPath with the paths in the correct order.
Windows NT/2000: Requires Windows 2000. Available as a redistributable for Windows NT 4.0.
Windows 95/98: Requires Available as a redistributable for Windows 98.
Header: Declared in Dbghelp.h.
Library: Use Dbghelp.lib.
Debug Help Library Overview, DbgHelp Functions, FindExecutableImageEx, SymGetSearchPath