TheSwamp
Code Red => AutoLISP (Vanilla / Visual) => Topic started by: fmn76 on July 22, 2007, 09:02:53 PM
-
Anyone can help me pls... i get this lisp from BTN Lisp... and get error like this...
Command: cpe wipeout Specify first point or [Frames/Polyline] <Polyline>: f
Enter mode [ON/OFF] <ON>: off Regenerating model.
Command:
Select point on contour line: insert Enter block name or [?]: el_tag Specify
insertion point or [Scale/X/Y/Z/Rotate/PScale/PX/PY/PZ/PRotate]:
Enter X scale factor, specify opposite corner, or [Corner/XYZ] <1>:
1.000000000000000 Enter Y scale factor <use X scale factor>: 1.000000000000000
Specify rotation angle <0>: ; error: bad argument value: AutoCAD command:
#<SUBR @05cf4410 PAUSE>
-
Perhaps try something like this ..
(DEFUN c:cpe (/ P VAL scl)
(COMMAND "wipeout" "f" "off")
(SETQ scl (GETVAR "dimscale")
om (GETVAR "osmode")
)
(SETVAR "osmode" 512)
(SETQ p (GETPOINT "\nSelect point on Contour Line: ")
val (RTOS (NTH 2 p) 2 0)
)
(COMMAND "insert" "el_tag" p scl scl pause)
(COMMAND val)
(SETVAR "osmode" om)
(PRINC)
)
-
hmm..ok im try ur lisp but still error come out...like this..... :|
Specify rotation angle <0>: ; error: bad argument value: AutoCAD command:
#<SUBR @04beaca8 PAUSE>
-
looks like you have a command overwriting the ACAD definition
what do you get for
(type pause)
?
-
I'd suggest you do a file search for a .LSP file that contains
defun pause
or just
pause
that's likely to be the problem
-
Hi fmn76,
test again this code
(defun c:cpe (/ om p pause scl val)
(command "wipeout" "f" "off")
(setq scl (getvar "dimscale"))
(setq om (getvar "osmode"))
(setvar "osmode" 512)
(setq p (getpoint"\nSelect point on Contour Line: "))
(setq val (rtos (nth 2 p) 2 0))
(command "insert" "el_tag" p scl scl pause val "")
(setvar "osmode" om)
(princ)
)
and you could look at attach file.
hmm..ok im try ur lisp but still error come out...like this..... :|
Specify rotation angle <0>: ; error: bad argument value: AutoCAD command:
#<SUBR @04beaca8 PAUSE>
-
Thanks ....Adesu & Kerry... i found that error... TQ again....
-
.. and the error was ?? ???
-
hmmmm ...
fmn76, What was the error ?
-
Sorry Kerry... actualy i combine my collection of lisp in 1 file... so that why have i have error in my lisp.... TQ again about ur idea/lisp...