Vb.net 取程序运行的绝对路径
来源:百度文库 编辑:神马文学网 时间:2024/04/26 20:09:45
Vb.net 取程序运行的绝对路径
━━━━━━━━━━━━━━━━━━━━━━━━━━取程序运行的绝对路径用 application.startuppath()
而CurDir是当前运行路径,但如果期间进行了打开文件或其它改变路径的操作后,CurDir返回的可能就不是程序运行的路径了,所以不推荐使用。
━━━━━━━━━━━━━━━━━━━━━━━━━━
Application.StartupPath 得到可执行文件的路径(bin文件夹下的)。
━━━━━━━━━━━━━━━━━━━━━━━━━━
Imports system.reflection.assembly
imports system.diagnostics.fileversioninfo
getExecutingassembly.location
━━━━━━━━━━━━━━━━━━━━━━━━━━
string curPath;
curPath = space(256);
GetCurrentDirectory(256, curPath)
if right(curPath,1)<>'\' then curPath +="\"
return curPath;
━━━━━━━━━━━━━━━━━━━━━━━━━━
━━━━━━━━━━━━━━━━━━━━━━━━━━取程序运行的绝对路径用 application.startuppath()
而CurDir是当前运行路径,但如果期间进行了打开文件或其它改变路径的操作后,CurDir返回的可能就不是程序运行的路径了,所以不推荐使用。
━━━━━━━━━━━━━━━━━━━━━━━━━━
Application.StartupPath 得到可执行文件的路径(bin文件夹下的)。
━━━━━━━━━━━━━━━━━━━━━━━━━━
Imports system.reflection.assembly
imports system.diagnostics.fileversioninfo
getExecutingassembly.location
━━━━━━━━━━━━━━━━━━━━━━━━━━
string curPath;
curPath = space(256);
GetCurrentDirectory(256, curPath)
if right(curPath,1)<>'\' then curPath +="\"
return curPath;
━━━━━━━━━━━━━━━━━━━━━━━━━━
Vb.net 取程序运行的绝对路径
demo:vb.net 打开记事本、beep、msgbox、取程序路径
VB.NET获取程序运行路径实现方法
VB开机运行程序
VB实现程序开机自动运行
1.4 第一个可视化vb.net程序
VB.NET progressbar 简单小程序
让.Net程序脱离.net framework框架运行的方法(转载) - kingeric的空间 - 博客园
用VS.NET编写的程序能否在没安装.NET Framework的电脑上运行?
ASP.NET 中得到网站绝对路径的几种方法
ASP.NET 中得到网站绝对路径的几种方法
让.Net程序脱离.net framework框架运行
vb.net的ListBox控件
vb.net的Combobox控件
vb.net的多维数组
请问VB能否在程序运行过程中将变量的值赋给数据库的字段? - VB6论坛 - 编程论坛
Hashtable 构造函数 ()的VB.NET例子
VB.Net处理文本文件的方法
VB.Net IndexOf的6种使用方法
VB.Net Split的4种使用方法
vb.net的Combobox控件1
vb.net入门--ErrorProvider 组件的使用
vb.net入门--NotifyIcon 组件的使用
VB.Net自动创建数据库的实例