See the top rated post in this thread. Click here

Page 1 of 3 123 LastLast
Results 1 to 10 of 25

Thread: How do people load their LISP routines?

  1. #1
    AUGI Addict Mr Cory's Avatar
    Join Date
    2007-01
    Location
    Under a Rock over there
    Posts
    1,006
    Login to Give a bone
    0

    Smile How do people load their LISP routines?

    Hay everyone,

    I was just after everyones opinion on whether its best to add all ones customs lisps to the acad.lsp or keep them seperate and just add the line (load "blah blah.lsp" " ") to acad.lsp?

  2. #2
    Administrator rkmcswain's Avatar
    Join Date
    2004-09
    Location
    Earth
    Posts
    9,832
    Login to Give a bone
    0

    Lightbulb Re: How do people load their LISP routines?

    Quote Originally Posted by Mr Cory
    Hay everyone,

    I was just after everyones opinion on whether its best to add all ones customs lisps to the acad.lsp or keep them seperate and just add the line (load "blah blah.lsp" " ") to acad.lsp?
    First off, it doesn't do any good to use "acad.lsp", because this file is only load once per session*. Lisp files must be loaded for each drawing that is loaded. "acaddoc.lsp" loads once per drawing, you should use this instead.

    I would suggest using the externally defined (autoload) function to load your lisp files in "acaddoc.lsp". This way the file doesn't actually load until it's needed. For more information, look up "autoload" in the Help file (acad_dev.chm).

    If you are not going to do that, then it doesn't really matter which method you choose. For the record, almost all our lisp functions are stored in separate files, with the exception of "universal" small routines like DTR, RTD, which are defined in "acaddoc.lsp".



    * unless ACADLSPASDOC is set to 1, which it shouldn't be
    R.K. McSwain | CAD Panacea |

  3. #3
    AUGI Addict Mr Cory's Avatar
    Join Date
    2007-01
    Location
    Under a Rock over there
    Posts
    1,006
    Login to Give a bone
    0

    Default Re: How do people load their LISP routines?

    O right, well beasically at the moment i have all my lisps either in acad.lsp of loaded from it. I have "load acad.lsp with every drawing" so you think i need to change how things are set up?

  4. #4
    Certifiable AUGI Addict ccowgill's Avatar
    Join Date
    2004-08
    Location
    Iron Station, NC
    Posts
    3,198
    Login to Give a bone
    0

    Default Re: How do people load their LISP routines?

    I dont use acad.lsp, I just load everything through acaddoc.lsp using a combination of load and autoload.

  5. #5
    Administrator rkmcswain's Avatar
    Join Date
    2004-09
    Location
    Earth
    Posts
    9,832
    Login to Give a bone
    0

    Lightbulb Re: How do people load their LISP routines?

    Quote Originally Posted by Mr Cory
    O right, well beasically at the moment i have all my lisps either in acad.lsp of loaded from it. I have "load acad.lsp with every drawing" so you think i need to change how things are set up?
    AutoCAD is designed so that acad.lsp is used to load items that need to be loaded "once per session", and acaddoc.lsp is used to load items that need to be loaded "once per drawing"

    You are using "acad.lsp" like it was back in R14 and earlier, before AutoCAD introduced MDI.

    More Info: http://rkmcswain.blogspot.com/2006/0...setup-and.html
    R.K. McSwain | CAD Panacea |

  6. #6
    Certifiable AUGI Addict robert.1.hall72202's Avatar
    Join Date
    2004-07
    Location
    Detroit Michigan
    Posts
    2,508
    Login to Give a bone
    0

    Default Re: How do people load their LISP routines?

    I have all of my lisp routines loaded in the startup suite.
    That may be why CAD loads somewhat slow.

    Judging by the comments, I am guessing it is not the best way
    to load routines.

    But hey, it works!

  7. #7
    Administrator rkmcswain's Avatar
    Join Date
    2004-09
    Location
    Earth
    Posts
    9,832
    Login to Give a bone
    0

    Talking Re: How do people load their LISP routines?

    Quote Originally Posted by Robert.Hall
    I have all of my lisp routines loaded in the startup suite.
    That may be why CAD loads somewhat slow.
    I don't know about slow, but the Startup Suite has had problems since it was introduced. For some it fails to load some items, for others it loads items twice. It's not as easy to migrate that list at upgrade time either, not to mention difficulties in a multiple user environment.
    R.K. McSwain | CAD Panacea |

  8. #8
    Certifiable AUGI Addict robert.1.hall72202's Avatar
    Join Date
    2004-07
    Location
    Detroit Michigan
    Posts
    2,508
    Login to Give a bone
    0

    Default Re: How do people load their LISP routines?

    Quote Originally Posted by rkmcswain
    I don't know about slow, but the Startup Suite has had problems since it was introduced. For some it fails to load some items, for others it loads items twice. It's not as easy to migrate that list at upgrade time either, not to mention difficulties in a multiple user environment.
    All very good points. I find that some routines have not loaded. Does not bother me too much because I rarely lose a routine that I use often.

    In addition to your cons, startup suite limits the number of lisp files you can load on the "add a file" screen. The user cannot surf to a directory, select all, and then add the entire folder. The lisp files would need to be added in small groups.

  9. #9
    Português - Programação Moderator Filipe Francisco's Avatar
    Join Date
    2001-12
    Location
    * PORTUGAL * Sintra *
    Posts
    859
    Login to Give a bone
    0

    Default Re: How do people load their LISP routines?

    I simply load mine lisp rotines when i need them...

    "appload" and save them in "Startup Suite"



    Cheers,

  10. #10
    AUGI Addict
    Join Date
    2005-08
    Posts
    1,043
    Login to Give a bone
    0

    Default Re: How do people load their LISP routines?

    I have custom menus (.mns, .cui, .mnl) which I use to load all my lisp routines. I have two. One loads all the shared subs, and one loads all the lisp files with (autoload ...... The .mnl files are the ones used to load the lisps and subs.

Page 1 of 3 123 LastLast

Similar Threads

  1. LISP routines
    By dawn.pedersen309807 in forum AutoLISP
    Replies: 25
    Last Post: 2012-08-28, 07:36 PM
  2. how do you call other lisp routines with lisp?
    By moises.y969653 in forum AutoLISP
    Replies: 1
    Last Post: 2011-02-06, 01:01 PM
  3. Lisp Routines
    By Shadrak in forum AutoCAD Customization
    Replies: 4
    Last Post: 2009-10-08, 01:32 AM
  4. Lisp Routines
    By jsnow in forum AutoCAD General
    Replies: 2
    Last Post: 2009-04-16, 05:07 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •