#PSTip Use Shell.Application to determine which folder is open in File Explorer
By using the Windows() method and the LocationURL and LocationName properties we can programmatically determine which folder is open in File Explorer.
|
|
The Where-Object statement is required to filter out results from Internet Explorer. If you are interested in all results including the open Internet Explorer windows and tabs the Where-Object statement can be omitted.
Share on: