I'm trying to get all the files in a directory and add them to a list. My problem is, is that the findnext function is not finding any more files in the directory even though I know there are more files. My goal is to find all the ds*.dbf files, but the code will only find 1 file and then exit. Can anybody see what is going on?
here is my code:
struct ffblk fileinfo;
//find all dsfbsxxx.dbf
iDone = findfirst(fileFolder, &fileinfo, 0);
sprintf(fileName, "scale\\data\\Sale%d\\%s",saleID, fileinfo.ff_name);
iDone = findnext(&fileinfo);