找回密码
 加入
搜索
查看: 1254|回复: 3

路径问题

[复制链接]
发表于 2009-9-14 21:43:17 | 显示全部楼层 |阅读模式
本帖最后由 redapple2008 于 2009-9-14 23:57 编辑

如果是D:\FlashFxp\flashfxp.exe这个路径,我想得到为D:\FlashFxp\这个目录怎么写代码?
发表于 2009-9-14 21:59:41 | 显示全部楼层
$I=stringsplit($path, "\")
stringtrimright($path, Stringlen($I[$I[0]]))
发表于 2009-9-14 23:22:55 | 显示全部楼层
#include <file.au3>
#include <array.au3>
Dim $szDrive, $szDir, $szFName, $szExt
$TestPath = _PathSplit("D:\FlashFxp\flashfxp.exe", $szDrive, $szDir, $szFName, $szExt)
MsgBox(0,"",$TestPath[1]&$TestPath[2])


 楼主| 发表于 2009-9-14 23:57:40 | 显示全部楼层
谢谢楼上两位,问题解决。
您需要登录后才可以回帖 登录 | 加入

本版积分规则

QQ|手机版|小黑屋|AUTOIT CN ( 鲁ICP备19019924号-1 )谷歌 百度

GMT+8, 2024-6-15 05:33 , Processed in 0.075571 second(s), 20 queries .

Powered by Discuz! X3.5 Licensed

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表