Group: Shell Functions - Library: shell32
Retrieves the name of and handle to the executable (.exe) file associated with the specified file name.
Accessing the list of Windows Recent Documents
How to find the application associated with a file name
How to make application automatically close all documents it opened
HINSTANCE FindExecutable(
LPCTSTR lpFile,
LPCTSTR lpDirectory,
LPTSTR lpResult
);
DECLARE INTEGER FindExecutable IN shell32;
STRING lpFile,;
STRING lpDirectory,;
STRING @lpResult
lpFile Address of a null-terminated string specifying a file name. This should be a document.
lpDirectory Address of a null-terminated string specifying the default directory.
lpResult Address of a buffer to receive the file name when the function returns.
Returns a value greater than 32 if successful, or a value less than or equal to 32 otherwise.
See also: ShellExecute, AssocQueryString.