得到驱动器信 [英] Getting Drive Letter

查看:57
本文介绍了得到驱动器信的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有没有办法从当前路径中提取驱动器号? 驱动器将是共享网络驱动器,但不同的用户将其映射到不同的字母。 或SAVEAS文件名:= CURDIR& " myfilename.xlsm"
总是保存到正确的地方而不管驱动器号?


谢谢

解决方案

获取驱动器号的一种方法是,


left(curdir,instr(curdir,":") - 1)


 


Is there a way that I can extract the drive letter from the current path?  Drives would be a shared network drive but different users will have it mapped to a different letter.  Or would a SAVEAS Filename:=CURDIR & "myfilename.xlsm" always save to the right place irrespective of drive letter?

Thanks

解决方案

One way to get the drive letter would be,

left(curdir,instr(curdir,":")-1)

 


这篇关于得到驱动器信的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆