I have writted a set of lisp routines with dcl files that I have implemented in most versions of Autocad since release 14. I can install the toolbars in Autocad 2013 but when I try to execute on of the commands, either by toolbar icon or command line, I get the message "Unknown Command".
I have added the appropriate paths to path list.
Dell Precision M4400 Laptop
Solved! Go to Solution.
From your description I would guess that the lisp functions have not been loaded in the drawing. What happens if you try to run the function defined as a command from the command line?
If you can't get this resolved, can you provide a small example that I can use to recreate the behavior?
I have 23 commands defined in Acad.lsp. These commands load and execute functions in 14 lisp files with 13 dcl files. An example of a command definition inAcad.lisp is as follows:
(defun C:BITDESIGN ()
(if (/= 1 (boole 1 1 (getvar "USERI1)))
The second line checks user variable USERI1 to see if "ddesign.lsp is already loaded; if not it is loaded.
bdesign is the routine executed in ddesign.lsp.
I have run the BITDESIGN command from its icon in a toolbar and from the command line. In each case I get the message "Unknown command "BITDESIGN".
This indicates that ACAD.LSP is not being loaded. I have added the proper path in "Tools/Options/Files". I have placed ACAD.LSP in the AutoCAD 2013/Support folder and in the AutoCAD/UserDataCache/Support folder. Is there another folder that I need to copy my acad.lsp folder to?. I have also checked the "Load Acad.lsp with each drawing" in the Tools/Options dialog.
Search your computer for all "Acad.lsp" files, autocad will load the first one it finds. It is probably finding one you are not aware of.
Since everything is loaded in the acad.lsp I would try placing an alert box line in the acad.lsp to see if it is loading.
Perhaps right before your first Defun.
(alert "its loading")
This way you know that it is indeed loading your acad.lsp.
>> This indicates that ACAD.LSP is not being loaded.Thanks,
Is there a path?
Check to see if ACADLSPASDOC and LISPINIT are set to 1.
An alternative is to rename the file to ACADDOC.LSP.
Sure enough there was another acad.lsp in the acadm folder. I appended my acad.lsp to that one and everything is working.
I have another situation but not really a problem. When I tried to install my lisp programs using a legacy .cui file, AutoCad wouldn't let me save the new .cuix file and the installation failed. I was logged on as myself (with administrator privileges). When I logged on as administrator, I had no problem with the installation. It's not really a problem since I can log on as administrator, but I was curious why it didn't work. Is this likely a Windows Vista problem rather than an AutoCad problem?
Log into access your profile, ask and answer questions, share ideas and more. Haven't signed up yet? Register
Start with some of our most frequented solutions to get help installing your software.