samifox Posted May 17, 2015 Share Posted May 17, 2015 hi regarding to acad.pgp. it has two applications , 1. mapping aliases to autcad commands 2. passing commands and parameters to the OS i want to talk about the second , its true that every application must be defined in the system search path in order to be invoked from autocad? how can i know all the available parameters of shell commands? for example , i want to set external command that invoke explorer.exe with specific folder opened? Thanks S Quote Link to comment Share on other sites More sharing options...
BIGAL Posted May 18, 2015 Share Posted May 18, 2015 (edited) Huh Explorer.exe c:\acadtemp Folders with spaces in ther names will be a problem need explorer.exe %1 old DOS days now where is that 20 year old book. No need (startapp "explorer" (getvar "dwgprefix")) check out the double slashes in the getvar. (startapp "explorer" "C:\\Acadtemp\\test dir space\\") Edited May 18, 2015 by BIGAL Quote Link to comment Share on other sites More sharing options...
tombu Posted May 18, 2015 Share Posted May 18, 2015 Couple examples: My Documents Folder: ^C^C^P(progn(startapp "explorer" (strcat "/n,/e," (getvar "mydocumentsprefix")))(princ)) Open Windows Explorer in Roamable Support Folder: ^C^C^P(progn(startapp "explorer" (strcat "/n,/e," (getvar "roamablerootprefix")"Support"))(princ)) Icon Folder: ^C^C^P(startapp "explorer" (strcat "/e, "(vla-get-CustomIconPath (vla-get-Files (vla-get-Preferences (vlax-get-acad-object)))))); Express Folder: ^C^C^P(progn(startapp "explorer" (strcat "/n,/e," (vl-filename-directory (findfile "acetauto.lsp"))))(princ)); Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.