We redirect user's "My Doc's" folders to a file server via group policy. Under the "My Doc's" folder, every user has another folder called "Scan Docs" which contains scanned pdf documents. I'm looking for a way to perform a weekly deletion of all .pdf's in each users "scan docs" folder located in their respective "my docs" folder. The folder tree looks something like the following:
\\server1\rfolders$\username1\mydocs - where "username1" is the users login id so each will be different.
I'm looking to run some type of batch delete command from server1. - something like:
But I can't get by the %username%