Menu Close

Get-OpenfileIDs

$ID = @()
$openfiles = net file
for ($x = 4; $x -lt $openfiles.count -2; $x++) {
$ID += ($openfiles[$x] -split "\s+")[0]
}

Something I’m twiddling with… you could also use the “openfiles.exe” command, which supports wildcarding IDs. Dunno where this snippet would be totally useful.

 3,394 total views,  1 views today

Leave a Reply

Your email address will not be published. Required fields are marked *