Important:
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.
A version of this page is also available for
4/8/2010

This function continues a file search from a previous call to the FindFirstFileor the FindFirstFileExfunction.

A RAPI version of this function exists called CeFindNextFile (RAPI).

Syntax

BOOL FindNextFile( 
  HANDLE 
hFindFile, 
  LPWIN32_FIND_DATA 
lpFindFileData 
); 

Parameters

hFindFile

[in] Search handle returned by a previous call to the FindFirstFileor the FindFirstFileExfunction.

lpFindFileData

[out] Pointer to the WIN32_FIND_DATAstructure that receives information about the found file or subdirectory. The structure can be used in subsequent calls to this function to refer to the found file or directory.

Return Value

Nonzero indicates success. Zero indicates failure. To get extended error information, call GetLastError. If no matching files can be found, GetLastErrorreturns ERROR_NO_MORE_FILES.

Remarks

When the search handle is no longer needed, close it by using the FindClosefunction.

This function searches for files by name only. It cannot be used for attribute-based searches.

Requirements

Header winbase.h
Library coredll.lib
Windows Embedded CE Windows CE 1.0 and later
Windows Mobile Windows Mobile Version 5.0 and later

See Also