mao
7/10/2017 - 1:51 AM

Get list of all known folders in Windows, even if user moved them to other non-standard locations. Answers the questions "How do I learn the

Get list of all known folders in Windows, even if user moved them to other non-standard locations. Answers the questions "How do I learn the path to the Desktop/Start Menu/Send To etc. directories?"

$result = [ordered]@{};

[Environment+SpecialFolder].GetEnumNames() -as [String[]] | 
    Sort | 
    ForEach {    $res += @{ $_=[Environment]::GetFolderPath($_) }   }
    
$result