vlisp获取系统桌面路径(发个帖备忘一下,方便以后好找!)
(strcat (vla-item (vlax-get (vlax-create-object "WScript.Shell" ) 'SpecialFolders) "Desktop") "\\")(getvar "dwgprefix") 也可以 张大锤 发表于 2018-7-25 11:13
(getvar "dwgprefix") 也可以
人家说的是“桌面” 收藏了好东东。 (command "shell" (strcat "explorer \""(getenv "userprofile")"\\Desktop\\\""))
(mapcar '(lambda (x) (setq x (vl-princ-to-string x)) (list x (getenv x)))
'(ALLUSERSPROFILE APPDATA CommonProgramFiles COMPUTERNAME ComSpec
EP_NO_HOST_CHECKHOMEDRIVE HOMEPATH LOCALAPPDATA LOGONSERVER NUMBER_OF_PROCESSORS
OneDrive OS Path PATHEXT PROCESSOR_ARCHITECTURE
PROCESSOR_IDENTIFIER PROCESSOR_LEVEL PROCESSOR_REVISION ProgramData
ProgramFiles PROMPT PSModulePath PUBLIC SESSIONNAME SystemDrive
SystemRoot TEMP TMP USERDOMAIN USERPROFILE windir
)
) 谢谢楼主分享,楼主是个热心人! 谢谢楼主分享,楼主是个热心人! (setq a (strcat (vla-item (vlax-get (vlax-create-object "WScript.Shell" ) 'SpecialFolders) "Desktop") "\\"))
"C:\\Users\\34468\\Desktop\\" 收藏一下,确实好用。
页:
[1]