Results 1 to 5 of 5

Thread: Auto loading a LSP but not auto running it

  1. #1
    Active Member
    Join Date
    2006-11
    Location
    Auckland, New Zealand
    Posts
    92
    Login to Give a bone
    0

    Default Auto loading a LSP but not auto running it

    I'm wanting to have a lisp routine automatically loaded for our users, but when I've placed it in the startup suite it autoruns upon opening autocad - which is causing major issues, as in AutoCAD won't complete it's startup. Is there anything I've done wrong, is it within the lisp that's caused the issue?

    All help greatly appreciated.
    Melanie Tristram
    Revit Manager - Jasmax Ltd - NZ

  2. #2
    Certifiable AUGI Addict
    Join Date
    2001-03
    Location
    Tallahassee, FL
    Posts
    3,447
    Login to Give a bone
    0

    Default Re: Auto loading a LSP but not auto running it

    Probably within the lisp, some coders call the function at the end of a routine to make it a one step process to load and run a routine.
    (defun xyz ()
    (some code...)
    )
    (xyz)

    You could put a semicolin in front of the call to run the routine as in:
    (defun xyz ()
    (some code...)
    )
    ;(xyz)

    You could post the code and how you're loading it here if that doesn't help.
    Tom Beauford P.S.M. - Civil 2020 on Windows 10 Enterprise
    Design Analysis - Leon County Public Works/Engineering Wrap [CODE] tags around selected text
    2280 Miccosukee Rd. Tallahassee, FL 32308-5310
    Ph# (850)606-1516 Home Page

  3. #3
    Certifiable AUGI Addict tedg's Avatar
    Join Date
    2005-06
    Location
    in the upper right corner
    Posts
    3,293
    Login to Give a bone
    0

    Default Re: Auto loading a LSP but not auto running it

    And/Or maybe adding a defun c: (command to run it)?
    Code:
    (defun c:xyz ()
    (some code...)
    )
    ;;(xyz)
    command: xyz
    Ted
    ____________________________________________________________________ ________________
    Windows 10
    AutoCAD 2018 - REVIT 2019 - Inventor Professional 2017 (when I can)

  4. #4
    Active Member
    Join Date
    2006-11
    Location
    Auckland, New Zealand
    Posts
    92
    Login to Give a bone
    0

    Default Re: Auto loading a LSP but not auto running it

    Ted & Tom,
    Thank you both for your replies - it was missing the semi-colon priof to the command run line

    (DEFUN C:PTL ()
    (Some code)
    )
    ;(C:PTL)
    Melanie Tristram
    Revit Manager - Jasmax Ltd - NZ

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

    Default Re: Auto loading a LSP but not auto running it

    FWIW -

    I am not a fan of using the APPLOAD Startup Suite; instead I use Acad.lsp and AcadDoc.lsp respectively, where the latter loads a list of AUTOLOAD statements for all LISP routines that I want to demand load, rather than dumping each onto the memory stack at drawing open. Faster load times, with all functionality available. Lemon squeezy.
    "How we think determines what we do, and what we do determines what we get."

    Sincpac C3D ~ Autodesk Exchange Apps

    Computer Specs:
    Dell Precision 3630, Core i9-9900K 5.0GHz, 128GB RAM, Samsung 970 Pro M.2, 8GB NVIDIA Quadro P4000

Similar Threads

  1. Auto LISP not loading
    By tjhernacki in forum AutoLISP
    Replies: 6
    Last Post: 2012-10-25, 05:06 PM
  2. mditabs 18 not auto loading
    By Liamnacuac in forum CAD Management - General
    Replies: 2
    Last Post: 2009-12-19, 12:13 AM
  3. auto running lisp
    By PHOTOS4ME in forum AutoLISP
    Replies: 3
    Last Post: 2009-07-31, 07:21 PM
  4. Auto Loading MNS files
    By Nick.Nemechek71583 in forum AutoCAD Customization
    Replies: 2
    Last Post: 2004-11-17, 04:33 PM
  5. Auto running a command.
    By bobr.71433 in forum AutoCAD Customization
    Replies: 2
    Last Post: 2004-07-10, 01:59 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
  •