2013年3月1日

总结C#获取当前路径的7种方法

摘要: http://wenku.baidu.com/view/ff493619ff00bed5b9f31d90.html//获取包含清单的已加载文件的路径或 UNC 位置。 public static string sApplicationPath = Assembly.GetExecutingAssembly ( ).Location; //result: X:\xxx\xxx\xxx.dll (.dll文件所在的目录+.dll文件名) //获取当前进程的完整路径,包含文件名(进程名)。 string str = this.GetType ( ).Assembly.Location; //res. 阅读全文

posted @ 2013-03-01 13:49 lj1918 阅读(209) 评论(0) 推荐(0) 编辑

导航