I can't speak for Glenn, but he may have discovered that wrapping every possible search scenario into a single process would be a bit overwhelming. Since he never posted a FAQ from this, I can only assume his attempt was incomplete.
As was said in the original thread, thread102-1418012 , the only real incentive was to try and turn out something that would be a lot more predictable than the original Sysutils findfirst/findnext. You can see that from the initial question in the thread.
I ultimately did some playing around and came up with what was posted within that thread, which has "must have" processing as opposed to "may have" processing. I would guess that is the difference and results in (IMO the bug since DOS days) the specified attr being irrelevant.
As the question could come out in the posts: "What is the point of specifying attr, if I have to post-filter?"
The code was only posted to be something enlightening, not really anything for FAQ material (though I can make it that way with a couple of extra notes - see
*). Sysutils is very similar - as you can see in the code, the Windows FindFirst/FindNext filters nothing. The code in the thread (and Sysutils for that matter) does that job. I would have to try it with the code I posted, but it might be interesting to see if it works by specifying "not faDirectory" for this OP's second question.
* - as most people code their own filters anyway, using faAnyFile, there is a lot of code in Sysutils.FindFirst and Sysutils.FindNext that gets run for basically no purpose. For this case, it's certainly better for efficiency sake to recode FindFirst/FindNext to simply call the Windows variants (without Attr in the function parms) and simply move the record data. This might be something to investigate if such a FAQ were to be written.
----------
Measurement is not management.