I think you want to list all your existing domain users and check for every directory in \\server\Profiles$\ if it is in this list. If it is not, do something to delete it.