All articles| All Pictures| All Softwares| All Video| Go home page| Write articles| Upload pictures

Reading number is top 10 articles
ASP.NET中MD5和SHA1加密的几种方法_.net资料_编程技术
SQL数据操作基础(中级)8_mssql学习_编程技术
C#教程:微软事务服务器应用实例
C#中EventLog组件应用实例
XSL教程:学会如何使用XPath入门_[XML教程]
《Effective,C#》之用委托实现回调_.net资料_编程技术
c#中GDI+图形图像:GDI+中的多边形使用方法
ASP.NET,2.0中预设的cookie_[Asp.Net教程]
.NET3.5正统分页控件来了(ListView和DataPager)_[Asp.Net教程]
PHP开发中接收复选框信息的方法_[PHP教程]
Reading number is top 10 pictures
男人,就要活出棱角
Nikon microscopic photography of the first three
美奂绝伦的风景
Absolutely shocked. National geographic 50 animal photographys4
Hunan road lawenforcement vehicle pursue overload car caused the car turn and man is died
赵惟依写真2
Magnificent cloud1
美丽的少女1
Group of female porn in 《westwards》, uninhibited woman threatened to not the bottom line2
王艳写真温柔如水1
Download software ranking
Tram sex maniac 2 (H) rar bag5
Photoshop 8.0图象编辑软件
Tram sex maniac 2 (H) rar bag19
塘西风月痕
C#与.NET技术平台实战演练
Unix video tutorial10
株洲本地在线棋牌游戏
功夫熊猫2(下集)
金山office2007
Eclipse-CALMSANNY (second edition)
归海一刀 published in(发表于) 2014/1/30 1:26:08 Edit(编辑)
c#得到文件路径-多种不同格式_[Asp.Net教程]

c#得到文件路径-多种不同格式_[Asp.Net教程]

c#得到文件路径-多种不同格式_[Asp.Net教程]
string str1 =Process.GetCurrentProcess().MainModule.FileName;//获得当前执行的exe的文件名。
string str2=Environment.CurrentDirectory;//获取和设置当前目录的完全限定路径。
string str3=Directory.GetCurrentDirectory();//获取应用程序的当前工作目录。
string str4=AppDomain.CurrentDomain.BaseDirectory;//获取基目录,它由程序集冲突解决程序用来探测程序集。
string str5=Application.StartupPath;//获取启动了应用程序的可执行文件的路径,不包括可执行文件的名称。
string str6=Application.ExecutablePath;//获取启动了应用程序的可执行文件的路径,包括可执行文件的名称。
string str7=AppDomain.CurrentDomain.SetupInformation.ApplicationBase;//获取或设置包含该应用程序的目录的名称。

“Application.StartupPath”:获取当前应用程序所在目录的路径,最后不包含“\”;
“Application.ExecutablePath ”:获取当前应用程序文件的路径,包含文件的名称;
“AppDomain.CurrentDomain.BaseDirectory”:获取当前应用程序所在目录的路径,最后包含“\”;
“System.Threading.Thread.GetDomain().BaseDirectory”:获取当前应用程序所在目录的路径,最后包含“\”;
“Environment.CurrentDirectory”:获取当前应用程序的路径,最后不包含“\”;
“System.IO.Directory.GetCurrentDirectory”:获取当前应用程序的路径,最后不包含“\”;


添加到del.icio.us 添加到新浪ViVi 添加到百度搜藏 添加到POCO网摘 添加到天天网摘365Key 添加到和讯网摘 添加到天极网摘 添加到黑米书签 添加到QQ书签 添加到雅虎收藏 添加到奇客发现 diigo it 添加到饭否 添加到飞豆订阅 添加到抓虾收藏 添加到鲜果订阅 digg it 貼到funP 添加到有道阅读 Live Favorites 添加到Newsvine 打印本页 用Email发送本页 在Facebook上分享


Disclaimer Privacy Policy About us Site Map

If you have any requirements, please contact webmaster。(如果有什么要求,请联系站长)
Copyright ©2011-
uuhomepage.com, Inc. All rights reserved.