The Everything_IsFolderResult function determines if the visible result is a folder.
BOOL Everything_IsFolderResult(
DWORD index
);
index
Zero based index of the visible result.
The function returns TRUE, if the visible result is a folder or volume (For example: C: or c:\WINDOWS).
The function returns FALSE, if the visible result is a file (For example: C:\ABC.123).
If the function fails the return value is FALSE. To get extended error information, call Everything_GetLastError.
Error code | Meaning |
---|---|
EVERYTHING_ERROR_INVALIDCALL | Call Everything_Query before calling Everything_IsFolderResult. |
EVERYTHING_ERROR_INVALIDINDEX | Index must be greater than or equal to 0 and less than the visible number of results. |
You can only call this function for a visible result. To determine if a result is visible use the Everything_GetNumFileResults function.
// set the search text to abc AND 123
Everything_SetSearch("abc 123");
// execute the query
Everything_Query(TRUE);
// determine if the first visible result is a folder.
BOOL bIsFolderResult = Everything_IsFolderResult(0);