如何确定一个命名的文件夹的完整路径? [英] How to determine a full path of a named folder?
本文介绍了如何确定一个命名的文件夹的完整路径?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我要确定某些文件夹的完整路径。在我的数组,我只是有文件夹的名称,但在我的应用程序将得到其他用户的机器安装,我的程序必须能够确定这些文件夹的完整路径。
I want to determine the full path of certain folders. In my array, I just have the names of the folders, but when my application will get installed on another user's machine, my program must be able to determine the full-path of these folders.
如何获得的完整路径?
推荐答案
你的意思是我的文档文件夹和其他人呢?这不是很明显,我从你的问题。
Did you mean the My Documents folder and the rest? It's not obvious for me from your question.
我的文档文件夹为:
Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments)
和特殊系统文件夹的剩余部分可以被检索以类似的方式
And the rest of the special system folders can be retrieved in a similar way.
这篇关于如何确定一个命名的文件夹的完整路径?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文