Results 1 to 10 of 10

Thread: ALIGNED LISP

  1. #1
    Active Member
    Join Date
    2012-07
    Posts
    56
    Login to Give a bone
    0

    Thumbs up ALIGNED LISP

    Hey guys,
    I need a lisp that calculate the distance between two points and put the distance in the midpoint above the line.

    Thanks in advance.
    Fabricio

  2. #2
    Active Member
    Join Date
    2012-07
    Posts
    56
    Login to Give a bone
    0

    Default Re: ALIGNED LISP

    Sorry guys...
    I've found this lisp.

    Thanks anyway

  3. #3
    Active Member
    Join Date
    2012-07
    Posts
    56
    Login to Give a bone
    0

    Default Re: ALIGNED LISP

    Hey guys,
    I need a lisp with the LAYON nad LAYTHW command together.

    Thanks in advance.
    Fabricio

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

    Default Re: ALIGNED LISP

    Have you ever used the command line version of the layer command?

    What prompts / inputs does a user need to do to accomplish your request?

    Did you know you could easily create this routine for yourself? It really isn't that difficult.

    Let's start off. To have a AutoLISP routine be executable by typing only the name of the routine, we would start off like this:
    Code:
    (defun c:thawall ()
    The first word in the code above tells AutoLISP that you want to define a function. This executable command is thawall. By prefixing the command name, we tell AutoLISP we do not want to have to run this command by surrounding it with parenthesis. The final set of parenthesis "()" are for some argument and local variable definitions. When the command is to be executable without surrounding with parenthesis, there cannot be any arguments. This routine you are trying to create most likely will not have any variables, either. That is why there is nothing between that set of parenthesis.

    You want to execute the layer command so we can thaw and turn on all the layers. To execute a AutoCAD command from AutoLISP, you would start the command function and surround the AutoCAD command with quotation marks.
    Code:
    (command "layer"
    For each option you want to execute, you would also place them within their own set of quotation marks.
    Code:
    "thaw"
    Code:
    "on"
    Of course, each one of those options asks for which layer names. You would provide that within another set of quotation marks.
    Code:
    "*"
    To end the layer command properly, we need to send an 'Enter' to AutoCAD. We would do that by adding an empty set of quotation marks and a closing parenthesis.
    Code:
    "")
    To finish defining the function, we need to also provide another closing parenthesis.
    Code:
    )
    Now, the code that I have provided above will work as long as you piece it together in the right order. Once it is pieced back together, you would execute this routine by typing "thawall" at the command line. Good luck.
    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

  5. #5
    Active Member
    Join Date
    2012-07
    Posts
    56
    Login to Give a bone
    0

    Default Re: ALIGNED LISP

    I'm going to try Opie...
    Thanks for the tips
    But if I didn't doing the routine, you'll give the full routine??

    Best Regards.

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

    Default Re: ALIGNED LISP

    I already did. It is just not put together. If it doesn't work, post it here and someone can point out what went 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

  7. #7
    Active Member
    Join Date
    2012-07
    Posts
    56
    Login to Give a bone
    0

    Default Re: ALIGNED LISP

    I did too.
    But didn't work as I expected.
    I think that I am doing something wrong.

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

    Default Re: ALIGNED LISP

    Post the code that you have compiled.
    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

  9. #9
    Active Member
    Join Date
    2012-07
    Posts
    56
    Login to Give a bone
    0

    Default Re: ALIGNED LISP

    Thanks, Opie...
    Very simple routine, but really useful.

    (defun c:thaw ();;Aqui é onde vc inseri o nome do comando
    (command "layon")
    (command "laythw")
    (princ)
    )

    Thanks!

  10. #10
    Active Member
    Join Date
    2016-02
    Location
    Singapore
    Posts
    70
    Login to Give a bone
    0

    Default Re: ALIGNED LISP

    Following Opie's suggestion will look something like this :

    Code:
    (defun c:LAyThawOn ()
    (command "-layer" "on" "*" "")
    (command "-layer" "thaw" "*" "")
    (princ))

Similar Threads

  1. None Aligned Drawings
    By mike.young in forum ACA General
    Replies: 1
    Last Post: 2009-06-09, 07:47 PM
  2. Aligned Dimension
    By sandeep_koodal in forum AutoCAD Tips & Tricks
    Replies: 2
    Last Post: 2008-11-26, 10:15 PM
  3. Arc Aligned Attributes
    By autocad.wishlist1734 in forum AutoCAD Wish List
    Replies: 0
    Last Post: 2008-10-11, 09:01 PM
  4. Aligned to Linear
    By Viswaprakash in forum CAD Standards
    Replies: 1
    Last Post: 2008-09-03, 08:46 PM
  5. Aligned Dimensions
    By charliep in forum Revit Architecture - General
    Replies: 5
    Last Post: 2006-03-13, 09:14 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
  •