TheSwamp

Code Red => AutoLISP (Vanilla / Visual) => Topic started by: Jeff_M on January 15, 2020, 02:46:14 PM

Title: Old AutoCAD lisp in newer IntelliCAD?
Post by: Jeff_M on January 15, 2020, 02:46:14 PM
Hey guys, it's been a while since I've posted in here. Someone using IntelliCAD 9.2 found a lisp that I posted back in 2003 for creating a true size set of railroad tracks. It still works fine for me testing in AutoCAD 2020 but he seems to be having an issue where it fails on the third polyline selected. If I were to write this lisp today I would definitely go about it differently, but really have no desire to rewrite it.

So, if anyone here can test in Intellicad and determine why it fails on the third running of it in the same file, I'd appreciate it. Just load the file, run the RRTRAX command, select  a polyline. I believe this was originally written prior to LWPOLYLINE objects, so to update it to work with them it converts those to the old heavy polyline then converts it back when done.

Thanks!
Title: Re: Old AutoCAD lisp in newer IntelliCAD?
Post by: ronjonp on January 15, 2020, 04:20:12 PM
The code errors out for me on the second run ( AutoCAD 2020 ). Don't have intellicad.
Quote
Command: _-block
Enter block name or [?]: TRACKS-2"
Invalid block name.
Cannot invoke (command) from *error* without prior call to (*push-error-using-command*).
Converting (command) calls to (command-s) is recommended.
*Tested in an empty drawing and it works fine...
Title: Re: Old AutoCAD lisp in newer IntelliCAD?
Post by: BIGAL on January 16, 2020, 08:43:47 PM
No idea but this is a comparison of local variables, 2nd list from Vlide.

( "blname" "bss" "bulge" "cntr" "curlyr" "e" "ename" "entstart" "etype" "lt" "ltoff" "lyrcount" "nent" "oldosnap" "osdone" "rr-cl" "rrlyr" "rt" "rtoff" "startpt" "TblLst" "tent")

  (*ERROR* @POLY BLNAME BSS BULGE CNTR CURLYR E E2 ENAME ENTEND ENTSTART LT LTOFF LYRCOUNT MYERROR NENT OLDERR OLDOSNAP OSDONE RRCL RRLYR RR_W RT RTOFF STARTPT TBLLST TENT)