GetDirList

Far Manager

GetDirList

The GetDirList function returns the list of files in the specified directory including subdirectories.
int WINAPI GetDirList(
  const char *Dir,
  struct PluginPanelItem **pPanelItem,
  int *pItemsNumber
);

Parameters

Dir
Name of the directory to scan. It can be a name only or a full pathname.
pPanelItem
Points to the variable that will receive the address of an array of PluginPanelItem structures.
When this array is no longer needed, it must be passed to the FreeDirList function.
pItemsNumber
Points to the variable that will receive the number of PluginPanelItem PluginPanelItem structures.

Return value

If the function succeeds, the return value is TRUE. If the function fails or directory scanning is cancelled by the user, FALSE is returned.

Remarks

  1. The function returns file names relative to the specified directory. For example, if Dir is D:\DIR1\DIR2, file names will be in DIR2\file.ext format.
  2. The user can interrupt the directory scanning process by pressing Esc. In this case the function will return FALSE.
See also: