Results 1 to 6 of 6

Thread: .lsp routines not working

  1. #1
    Member
    Join Date
    2010-02
    Posts
    3
    Login to Give a bone
    0

    Default .lsp routines not working

    Using ACAD 2012, Windows 7, 64-bit

    I'm having a little problem...

    I have a number of .lsp routines that I have loaded into the startup suite. I have them pathed correctly and at the top of the list in the support file search path under options.

    Problem is...they load into the drawing when a drawing is opened, but they will not execute. If I type APPLOAD and re-load them individually, they all seem to work fine.

    I'm only having this problem with the computers that are running 2012 in the office

    Any help is greatly appreciated

  2. #2
    Administrator BlackBox's Avatar
    Join Date
    2009-11
    Posts
    5,714
    Login to Give a bone
    0

    Default Re: .lsp routines not working

    Welcome to AUGI!

    I've never been a fan of Startup Suite, personally, instead I use ACADDOC.lsp to AUTOLOAD my routines into each drawing opened.

    HTH
    "How we think determines what we do, and what we do determines what we get."

    Sincpac C3D ~ Autodesk Exchange Apps

    Computer Specs:
    Dell Precision 3660, Core i9-12900K 5.2GHz, 64GB DDR5 RAM, PCIe 4.0 M.2 SSD (RAID 0), 16GB NVIDIA RTX A4000

  3. #3
    Member
    Join Date
    2010-02
    Posts
    3
    Login to Give a bone
    0

    Default Re: .lsp routines not working

    Can you attach a copy of an acaddoc.lsp for me to reference?

    Thanks.

    Mike

  4. #4
    Administrator BlackBox's Avatar
    Join Date
    2009-11
    Posts
    5,714
    Login to Give a bone
    0

    Default Re: .lsp routines not working

    Quote Originally Posted by michael.243371 View Post
    Can you attach a copy of an acaddoc.lsp for me to reference?
    No, I cannot. But I can assist you in creating your own, or attempt to answer any questions that you may have.

    In short, ACADDOC.lsp is a user defined file that is automagically loaded into every drawing that is opened, provided one resides within the Support File Search Path (SFSP).

    This file does not come with AutoCAD, and can be created by any text editor (i.e., Notepad, Notepad++, etc.) where the text file is saved with a .LSP file extension.

    If your going to learn LISP though, then I'd instead suggest that you consider usign the Visual LISP Integrated Development Environment (VLIDE) for .LSP file creation.

    HTH
    "How we think determines what we do, and what we do determines what we get."

    Sincpac C3D ~ Autodesk Exchange Apps

    Computer Specs:
    Dell Precision 3660, Core i9-12900K 5.2GHz, 64GB DDR5 RAM, PCIe 4.0 M.2 SSD (RAID 0), 16GB NVIDIA RTX A4000

  5. #5
    Member
    Join Date
    2010-02
    Posts
    3
    Login to Give a bone
    0

    Default Re: .lsp routines not working

    How's this for starters?
    Attached Files Attached Files

  6. #6
    Administrator BlackBox's Avatar
    Join Date
    2009-11
    Posts
    5,714
    Login to Give a bone
    0

    Default Re: .lsp routines not working

    Strictly using the LOAD statement is common when first starting. It's effective, it's simple, and there's loads of room for improvement (pun intended).

    For instance, LOADing all routines places each one in memory at drawing open, which not only takes time; but also will proceed to clog up your memory stacks when your code library grows. Then you may typically prefer the advantages of using AUTOLOAD instead; it makes all of your routines available without actually loadin them into memory until the first time the command is invoked.

    Another thing, personal preference albeit, is to end each routine with (princ) to prevent unwanted returned values from bein displayed at the command line.

    Also consider using a FOREACH statement for loading a list of routines.

    Again, nothing wrong with what you have, yet stil room to improve.

    HTH
    "How we think determines what we do, and what we do determines what we get."

    Sincpac C3D ~ Autodesk Exchange Apps

    Computer Specs:
    Dell Precision 3660, Core i9-12900K 5.2GHz, 64GB DDR5 RAM, PCIe 4.0 M.2 SSD (RAID 0), 16GB NVIDIA RTX A4000

Similar Threads

  1. Object snaps not working in lisp routines in 2012
    By jrp.31023 in forum AutoLISP
    Replies: 5
    Last Post: 2012-11-01, 06:39 AM
  2. Loading Routines
    By BeKirra in forum AutoLISP
    Replies: 2
    Last Post: 2011-02-08, 09:12 AM
  3. My startup suite lisp routines are not working properly
    By jim.dozorec in forum AutoCAD General
    Replies: 6
    Last Post: 2007-09-12, 01:25 PM

Posting Permissions

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