在一个文件夹下有多个日志文件,格式相同.怎么连续读取所有文件.我写了一段程序,可是老出问题,烦请高手帮忙看看.....
struct _finddata_t findData;

long hFile;hFile = _findfirst("event*.log", &findData);while (hFile != -1L)
{
hFile = (long)_findnext(hFile, &findData); cout << findData.name << " 文件已读取.." << endl;
....

}
_findclose(hFile);
...

在运行时,Event.log 文件不能读,其他文件(如event001.log)则能读,但最后一个文件读两次,请问这是怎么回事?急等....