Old topic that is not answered anywhere online - recursively block folder

I have read many threads about this question and none of the suggestions actually work.

I want to be able to select a folder and have all of the applications recursively contained within that folder blocked access from the web.
There was a post about there being a sound reason for not allowing this. But the reason was actually just filler air and not sound at all. In fact no reason. It just said some nonsense like files are contained in folders. WOW, very sound. I learned something there. Did any of you know that files are in folders. Well that was helpful right?

This is the thing, why not just make your code so it recursively looks for EXE’s within a folder and all subfolders. Then generate that as a list in front of the user and say, “Do you want to make rules for all of these?” Then if they say yes. You say, ok what is the rule. Then the user selects block. Then presto there are 38 rules all seperate but all blocking various EXEs

Just code that instead of telling us that folders contain files as a sound reason for not trying.

Did you try creating a File Group then using Add Folder. Then apply the rule to File Group?