Page 1 of 2 12 LastLast
Results 1 to 10 of 11

Thread: LISP loading, not finishing, no errors.

  1. #1
    Active Member
    Join Date
    2009-03
    Posts
    63
    Login to Give a bone
    0

    Default LISP loading, not finishing, no errors.

    Hi all, I have a weird problem and I'm coming up blank on google and forum searches. I have a lisp I wrote to combine 3 or 4 actions our drafters perform many times a day and also remove a large degree of user error. Granted my programing skills are lukewarm at best, but the program does work as expected on all our machines except one. On this one the program starts and after the first user input phase just cancels out, back to command line. no errors, but the program is not finishing. I'm drawing a blank. we're using Civil 3D 2012 on Windows 7 Professional machines. Have tested program on an older WinXP Machine running Civ3D 2012 and works there too. I've tried checking support paths, and re-loading the lisp with APPLOAD once drawing is running. I don't want to try re-installation before the weekend because its a non-vital routine and I don't want a drafter losing productive time during the installation. I'd like to avoid re-installation unless its necessary.

    If anyone can think of a direction to point me in I would greatly appreciate it.

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

    Default Re: LISP loading, not finishing, no errors.

    It could be any number of things, a conflict with a sysvar, something expected is not present, all sorts of things.
    Can you post the code?
    R.K. McSwain | CAD Panacea |

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

    Default Re: LISP loading, not finishing, no errors.

    99% chance it's your routine, it's happened to me often enough. Usually from (command ... calls which have to assume the expected response which may depend on a number of variables such as peditaccept, expert, etc... or if the current Text Style prompts for height or has it assigned. No way to pick your code apart without seeing it. Post the code.

  4. #4
    Active Member
    Join Date
    2009-03
    Posts
    63
    Login to Give a bone
    0

    Default Re: LISP loading, not finishing, no errors.

    Here (hopefully, have never attached files on this board before) is the code. It utilizes some layers and dimension styles proprietary to our templates but hopefully otherwise its clear.

    Be forewarned, this is a GIGANTIC kludge, as I said my programing skills are self taught and lukewarm at best, mostly cannibalized code.

    LEGALFOOT.lsp

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

    Default Re: LISP loading, not finishing, no errors.

    You might consider Lee's excellent Debugging Code with the Visual LISP IDE tutorial... Step through your code line by line until you see where it breaks.

    ** Edit to add - Even if the code doesn't break per-se, use the Watch tool to make sure that values, results, etc. are correct as the code progresses.
    "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

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

    Default Re: LISP loading, not finishing, no errors.

    Another of Lee's tutorials that you may find useful... Localizing Variables
    "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

  7. #7
    Active Member
    Join Date
    2009-03
    Posts
    63
    Login to Give a bone
    0

    Default Re: LISP loading, not finishing, no errors.

    some good stuff there RenderMan, I had already stepped through the program on my machine with no luck (going to try the offending machine tonight when the drafter leaves for the day) but localizing variables makes good sense, I do use a few generic names that might be mixing unbeknownst to me. Worst case it can't hurt amirite?

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

    Default Re: LISP loading, not finishing, no errors.

    Quote Originally Posted by ccalder View Post
    some good stuff there RenderMan...
    No worries; Lee did all the work.

    Quote Originally Posted by ccalder View Post
    ... Worst case it can't hurt amirite?
    In my limited experience... Localizing variables, and including sufficient error handling (to restore changed sysvars, release external interface objects, etc.) quickly become essential as one develops more complex code.

    It's best to consider these best practices early on, in order to mitigate the learning curve down the road, methinks.
    "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

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

    Default Re: LISP loading, not finishing, no errors.

    Had to add a couple layers, but it ran fine on my PC after that. I got errors before that which he didn't. That eliminates a lot of things. You could check to see if Aecc commands run on his setup. If not you may be able to fix it by switching or loading another profile. Use (findfile "legalfoot.lsp") to make sure his PC is loading the same version of your routine. He may have saved his own version locally.

  10. #10
    Active Member
    Join Date
    2009-03
    Posts
    63
    Login to Give a bone
    0

    Default Re: LISP loading, not finishing, no errors.

    Just an update if anyone hits this thread searching for a similar problem. You nailed it Tom, after the drafter left I used the findfile and discovered that this drafter was loading a bad previous version one folder up in her support folder hierarchy (don't ask me how or why), so corrected that and tried again, and now I'm hitting errors, it turns out this drafter has been changing the names on some of our master template layers in her work which of course caused errors, so lesson for me here, is to never assume that certain layers will be present, this should be an easy fix with one or two extra lines of code. After correcting the one-two punch there, it worked like a charm! Thanks to all who replied!

Page 1 of 2 12 LastLast

Similar Threads

  1. Replies: 2
    Last Post: 2015-04-17, 04:00 PM
  2. problem finishing lisp command
    By prose in forum AutoLISP
    Replies: 2
    Last Post: 2008-11-13, 01:51 AM
  3. Errors when loading linked files??
    By patricks in forum Revit - Platform
    Replies: 4
    Last Post: 2008-01-14, 09:22 PM
  4. Design Review loading errors
    By Jshaver in forum Design Review - General
    Replies: 3
    Last Post: 2007-10-03, 01:54 PM
  5. loading lisp
    By richardl in forum VBA/COM Interop
    Replies: 1
    Last Post: 2004-06-11, 05:37 PM

Tags for this Thread

Posting Permissions

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