Results 1 to 8 of 8

Thread: Start Up Lisp Help

  1. #1
    All AUGI, all the time BCrouse's Avatar
    Join Date
    2003-04
    Location
    Bethlehem, PA
    Posts
    980
    Login to Give a bone
    0

    Question Start Up Lisp Help

    In this Zip file you will find to lisp files. How would I add this (fixtextstyle.lsp) to the Phc lisp so that it will be automatically loaded?

    Thank you,

    Brad
    Attached Files Attached Files

  2. #2
    AUGI Addict madcadder's Avatar
    Join Date
    2000-11
    Location
    Too far from the beach
    Posts
    1,054
    Login to Give a bone
    0

    Default Re: Start Up Lisp Help

    Two ways:

    (autoload "fixtextstyle.lsp" '("fx"))

    or

    (load "fixtextstyle.lsp)

    The first way autoloads the routine on first use and will be stay loaded for the rest of the drawing session.
    The second way loads the routine when it comes to it when that LISP is run.

    I thought

    (defun c:RemArchT (/)
    (autoload "fixtextstyle.lsp" '("fx"))
    (c:RKTI)
    (c:RURL)

    looked just fine, but didn't really look at the rest of the routine.

  3. #3
    Administrator Opie's Avatar
    Join Date
    2002-01
    Location
    jUSt Here (a lot)
    Posts
    9,096
    Login to Give a bone
    0

    Default Re: Start Up Lisp Help

    Quote Originally Posted by todw
    Two ways:

    (autoload "fixtextstyle.lsp" '("fx"))

    or

    (load "fixtextstyle.lsp)

    The first way autoloads the routine on first use and will be stay loaded for the rest of the drawing session.
    The second way loads the routine when it comes to it when that LISP is run.

    I thought

    (defun c:RemArchT (/)
    (autoload "fixtextstyle.lsp" '("fx"))
    (c:RKTI)
    (c:RURL)

    looked just fine, but didn't really look at the rest of the routine.

    What type of problems are you having regarding the loading of the fixtextstyle.lsp? As todw responded on your question, you need to load the file with [code[(load "fixtextstyle.lsp")[/code] You would then call the function name you are trying to run (c:fx)

    Being that a "STYLE" is not an entity, I don't believe you can modify the "STYLE" with entmod. (I could be wrong)
    If you have a technical question, please find the appropriate forum and ask it there.
    You will get a quicker response from your fellow AUGI members than if you sent it to me via a PM or email.
    jUSt

  4. #4
    All AUGI, all the time BCrouse's Avatar
    Join Date
    2003-04
    Location
    Bethlehem, PA
    Posts
    980
    Login to Give a bone
    0

    Question Re: Start Up Lisp Help

    Quote Originally Posted by richardl.25628
    What type of problems are you having regarding the loading of the fixtextstyle.lsp? As todw responded on your question, you need to load the file with [code[(load "fixtextstyle.lsp")[/code] You would then call the function name you are trying to run (c:fx)

    Being that a "STYLE" is not an entity, I don't believe you can modify the "STYLE" with entmod. (I could be wrong)
    Do I add what todw said to the fixtextstyle.lsp or the the Phc.lsp? If I add it the the Phc.lsp how would it look?

  5. #5
    Administrator Opie's Avatar
    Join Date
    2002-01
    Location
    jUSt Here (a lot)
    Posts
    9,096
    Login to Give a bone
    0

    Post Re: Start Up Lisp Help

    Quote Originally Posted by BCrouse
    Do I add what todw said to the fixtextstyle.lsp or the the Phc.lsp? If I add it the the Phc.lsp how would it look?
    You would need to add it to the phc.lsp file

    Code:
      ; This will load the fixtextstyle.lsp file.  This file must
      ; be able to be found within your support directories.
    (load "fixtextstyle.lsp")
    
      ; This then runs the c:fx function as you have it defined
      ; in the fixtextstyle.lsp file
    (c:fx)
    Again, I do not think you can entmod a text style.

    I hope this helps.
    If you have a technical question, please find the appropriate forum and ask it there.
    You will get a quicker response from your fellow AUGI members than if you sent it to me via a PM or email.
    jUSt

  6. #6
    All AUGI, all the time BCrouse's Avatar
    Join Date
    2003-04
    Location
    Bethlehem, PA
    Posts
    980
    Login to Give a bone
    0

    Question Re: Start Up Lisp Help

    Thank you todw and richard.25628 for your help. I got it to work now. How could I get this to update and save the text styles when publish is running? Is it possible? How could I get this to update dwgs that are xref'd?

    Thank you,

    Brad

  7. #7
    The Silent Type RobertB's Avatar
    Join Date
    2000-01
    Location
    Seattle WA USA
    Posts
    5,859
    Login to Give a bone
    0

    Default Re: Start Up Lisp Help

    Quote Originally Posted by BCrouse
    How could I get this to update and save the text styles when publish is running? Is it possible?
    Code will not execute in a background publish operation.

  8. #8
    I could stop if I wanted to tyshofner's Avatar
    Join Date
    2004-03
    Location
    Dallas, Tx
    Posts
    229
    Login to Give a bone
    0

    Default Re: Start Up Lisp Help

    How could I get this to update dwgs that are xref'd?
    I'm not sure that this is possible, you could get the routine to change width factors or actually change the style (thats change the style that a text object uses, not the actual "style") in the current drawing, but it's not very practical plus the changes will be undone as soon as the xref is reloaded. Your best bet is to just run the routine on each individual drawing.

    Ty

Similar Threads

  1. Dim Style Lisp help - where to start
    By gfreddog in forum AutoLISP
    Replies: 11
    Last Post: 2009-12-04, 07:31 AM
  2. Learning how to use Reactors in LISP, where to start
    By rajat_bapi_mallick in forum AutoLISP
    Replies: 2
    Last Post: 2007-05-25, 03:05 AM
  3. Replies: 6
    Last Post: 2007-04-27, 05:54 PM
  4. Replies: 5
    Last Post: 2006-12-08, 03:20 AM
  5. Loading lisp code at start up
    By cadd4la in forum AutoLISP
    Replies: 4
    Last Post: 2006-01-31, 04:45 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
  •