How To Disconnect Users Accessing a Windows Shared Folder using PowerShell
- by Martin Hollingsworth
The Determine Users Accessing a Shared Folder Using PowerShell question has a good answer. Continuing on from that How do you disconnect the users accessing the share using a powershell script.
There is a Windows command line utility called OpenFiles but I'd prefer a PowerShell / WMI solution.