什么是C#语法要检索Windows用户的桌面,文件夹以及其他系统文件夹?
What is the C# syntax to retrieve the user's desktop, documents folder and other system folders on windows?
您可以使用Environment.GetFolderPath与Environment.SpecialFolder枚举。例如:
You can use Environment.GetFolderPath with the Environment.SpecialFolder enumeration. For example:
string desktopPath = Environment.GetFolderPath(Environment.SpecialFolder.Desktop);