大神 C:%users\Administrator\appdata\local\temp\23FX-06.dwg 如果想要temp\23FX-06怎么改?
(setq tem(last(LM:str->lst (vl-filename-directory (setq str "C:\\Users\\Administrator\\appdata\\local\\temp\\23FX-06.dwg")) "\\")))
(strcat tem "\\" (vl-filename-base str))
;下为调用函数
(defun LM:str->lst (str del / pos)
(if (setq pos (vl-string-search del str))
(cons (substr str 1 pos)
(lm:str->lst (substr str (+ pos 1 (strlen del))) del)
)
(list str)
)
) xj6019 发表于 2023-5-2 08:09
(setq tem(last(LM:str->lst (vl-filename-directory (setq str "C:\%users\\Administrator\\appdata\\lo ...
非常感谢大神!!!
页:
1
[2]