The two codes below have been used by my office since before i started working here. They've worked fine in the past and today they decided to stop. I get this error for the first one:
Command: sa
Pick insertion point:
Angle?:
; error: An error has occurred inside the *error* functiontoo many arguments
; error: An error has occurred inside the *error* functiontoo many arguments
Unknown command "SA". Press F1 for help.
and this error for the second one:
Command: 4SA
NPICK POINT; error: An error has occurred inside the *error* functiontoo many
arguments
; error: An error has occurred inside the *error* functiontoo many arguments
Unknown command "SA". Press F1 for help.
Unknown command "@15,0". Press F1 for help.
48.000000
LISP command is not available.
48.000000
(yes they are both loaded i double and triple checked that)
Code:
inserts air direction arrow (supply)
(defun c:sa ()
(setq ortho (getvar "orthomode"))
(setq scl (getvar "dimscale" ))
(setvar "orthomode" 1)
(setq pnt (getpoint "\nPick insertion point:" ))
(setq a (getangle "\nAngle?:" pnt ))(terpri)
(setq ang ( * a 57.3))
(command "layer" "set" "txt" "")
(command "insert" "sa" pnt scl scl ang)
)
Code:
inserts 4 way air direction arrows for diffuser
(defun c:4sa ()
(SETVAR "OSMODE" 64)
(SETQ INS (GETPOINT "\NPICK POINT"))
(COMMAND "ID" INS)
(setvar "clayer" "txt")
(setq scl (getvar "dimscale" ))
(command "insert" "sa" "@15,0" scl scl 0)
(COMMAND "ARRAY" "LAST" "" "POLAR" "@-15,0" "4" "" "" )
(SETVAR "OSMODE" 0)
)
Bookmarks