- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
I have a lisp routine I would use years back that is no longer working.
Essentially the routine before would get rotation, starting number, and increment (number to add / subtract). But the routine does not function as it did before. What happened to the variables?
The big glitch is it no longer edits the attribute, it opens a diaglog box to enter instead of entering from command line script My suspicion is that something changed with attribute definitions. Any advice? I feel like theres a system variable that needs to be set then reset.
The ROUTINE is shown below:
;Name : AddNUM.lsp
;Command : AddNUM
;created by jeremiah bowles
;******************************************************************
(defun c:Raddnum ()
;convert to degrees
; Convert value in radians to degrees
(defun Radian->Degrees (nbrOfRadians)
(* 180.0 (/ nbrOfRadians pi))
)
;setting rotation angle
; origional
; (setq rot (getangle "\nPick rotational angle:"))
; (setq rotd (* 180.0 (/ rot pi)))
;final script rotation if null
(setq rot (getangle "\nPick rotational angle:"))
(if (null rot) (setq rotd 0) (setq rotd (* 180.0 (/ rot pi)))
)
;setting the variables
(setq beg (getint "\nBegining of sequence of wall panel :"))
(setq pit (getint (strcat "\nIncrement :[ " "1" " ]")))
(if (= pit nil) (setq pit 1))
(setq k pit)
(while
(setq pt(getpoint "\nPick point :"))
(command "insert" "walltag" "r" rotd pt "1" "1" beg)
(prompt (strcat "<< " (rtos beg) " >>"))
(setq beg (+ beg k))
)
)
Solved! Go to Solution.