 - (defun c:fd ()
- (princ "打开文件所在文件夹\n选择文件:")
- (setq name(getfiled "指定文件" (getvar "dwgprefix") "dwg" 0))
- (setq position
- (vl-string-search "\\" name 4))
- (setq np position)
- (while (numberp position )
- (setq position
- (vl-string-search "\\" name (1+ position)))
- (if (/= position nil)(setq np position))
- )
- (setq tn(substr name 1 np))
- (mapcar 'princ (list "\n文件路径=" tn))
- (startapp "explorer" tn)
- (prin1)
- )
你根据这个改一改,就懒得给你具体弄了
|