Author Topic: Lisp 2008 vs 2012  (Read 1740 times)

0 Members and 1 Guest are viewing this topic.

Atwist

  • Guest
Lisp 2008 vs 2012
« on: August 12, 2012, 01:38:52 PM »
Hello,
I walk maybe a little behind in terms off AutoCad.
But I have a question about AutoCAD 2012, I would like to use LISP for AutoCAD 2008 only half works.
Does anyone know how I can solve this.
There's probably a migration tool but I can not find it.

Jeff_M

  • King Gator
  • Posts: 4096
  • C3D user & customizer
Re: Lisp 2008 vs 2012
« Reply #1 on: August 12, 2012, 02:28:35 PM »
Very little, if anything, was changed between 2008 & 2012. In other words, any lisp written for 2012 should work in 2008 .... unless it is using ActiveX objects that weren't exposed in 2008. Post the code and the errors/problems you are having and someone should be able to help you.

Atwist

  • Guest
Re: Lisp 2008 vs 2012
« Reply #2 on: August 12, 2012, 02:57:18 PM »
I would like to use Lisp for AutoCAD 2008 in AutoCAD 2012.
Because I will soon upgrade to AutoCAD 2012.

Jeff_M

  • King Gator
  • Posts: 4096
  • C3D user & customizer
Re: Lisp 2008 vs 2012
« Reply #3 on: August 12, 2012, 03:23:15 PM »
Most lisp files from 2008 will also work in 2012. There are a few cases where the command line options have changed so those lisps using (command .....) may need to be slightly altered. But otherwise you shouldn't have any problems. If you do, then post specific problems as they come up. (I still use many of the exact same lisps I wrote back for R14.)

irneb

  • Water Moccasin
  • Posts: 1794
  • ACad R9-2016, Revit Arch 6-2016
Re: Lisp 2008 vs 2012
« Reply #4 on: August 13, 2012, 05:09:18 AM »
Exactly! Most of lisp is still working. I've even seen routines which were created in the '80s for ACad R9 (DOS) still perform exactly in 2012 as they did back then - without any modifications.

There are some things that have changed, but the chances are that forward compatibility (like you're describing) would work just fine. There's only 2 things which might go wrong from 2008 to 2012 (as Jeff's already noted):
  • Some ActiveX objects / methods / properties might have been changed, though I highly doubt this, and have not come across such as yet.
  • The commands may have gotten some other command-line arguments. This I have seen happen, and it is usually the reason LSP's break on newer ACads.
For both options it's not difficult to find out where the issue is, especially if you use VLIDE's debugging features. From there the fix is usually extremely minor: moving an argument input from here to there, or sending the new name, etc.
Common sense - the curse in disguise. Because if you have it, you have to live with those that don't.

dgorsman

  • Water Moccasin
  • Posts: 2437
Re: Lisp 2008 vs 2012
« Reply #5 on: August 13, 2012, 10:24:15 AM »
There isn't any automated migration tools for LISP, other than the PEBKAC.   :angel:
If you are going to fly by the seat of your pants, expect friction burns.

try {GreatPower;}
   catch (notResponsible)
      {NextTime(PlanAhead);}
   finally
      {MasterBasics;}