|
From: Matthews <dem...@uw...> - 2003-09-05 03:03:38
|
For non-portable, use <io.h>, and _findfirst(), _findnext() and _findclose(). It's not hard to figure out, just save the find handle from _findfirst() in an int to use with _findclose(). At 01:50 PM 04/09/2003 +0200, P.D. van Zelst wrote: >You're probably best off using the Win32 API functions FindFirstFile, >FindNextFile and FindClose... if you don't need portable code >(cross-platform code). Those functions will give you information about >the files matching a certain mask (*.txt for example) in the directory >you specify. You can then use this information to open the files if you >like. If you only need standard information, like the filesize for >example, you don't need to do anything else -- FindFirstFile and >FindNextFile already supply this information (using the WIN32_FIND_DATA >struct). |