我正在尝试在64位操作系统中获取Program Files目录.以下代码返回相同的答案Program Files (x86)
:
Console.WriteLine(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFilesX86).ToString());
Console.WriteLine(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles).ToString());
Run Code Online (Sandbox Code Playgroud)
有帮助吗?
c# ×1