See the top rated post in this thread. Click here

Page 1 of 3 123 LastLast
Results 1 to 10 of 21

Thread: block and table lisp

  1. #1
    Member
    Join Date
    2009-12
    Posts
    20
    Login to Give a bone
    0

    Default block and table lisp

    Hi,

    I looking for a lisp that could extract attribute values from blocks that I select and use a formula like a sum of the same values and make automaticly a table, the values are GKW, FLOW and KPA, the table is called GKW totaal, I want to have these values in a small table witch I can place on screen.

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

    Default Re: block and table lisp

    What you are looking for is available in AutoCAD already, in the form of the ._DATAEXTRACTION command.
    R.K. McSwain | CAD Panacea |

  3. #3
    Member
    Join Date
    2009-12
    Posts
    20
    Login to Give a bone
    0

    Default Re: block and table lisp

    Yes I know, but it take too much time I have to do it maybe100 times in one drawing, so I'm looking for an automatic lisp or vba who can do it all in just one handling, like select a few blocks and put the date with a formula in a table or predefined block.
    Last edited by john.237249; 2010-01-31 at 03:30 PM.

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

    Default Re: block and table lisp

    Ok. Do you have any code that you have started or are you looking for someone to write the entire thing for you? There is some code here showing how to create a table using lisp, although not specifically dealing with attributes.

    You might also check out some existing routines such as:
    http://cadtips.cadalyst.com/export/a...ta-extractions
    and
    http://cadtips.cadalyst.com/attribut...butes-csv-file
    R.K. McSwain | CAD Panacea |

  5. #5
    AUGI Addict fixo's Avatar
    Join Date
    2005-05
    Location
    Pietari, Venäjä
    Posts
    1,269
    Login to Give a bone
    0

    Default Re: block and table lisp

    Quote Originally Posted by john.237249 View Post
    Hi,

    I looking for a lisp that could extract attribute values from blocks that I select and use a formula like a sum of the same values and make automaticly a table, the values are GKW, FLOW and KPA, the table is called GKW totaal, I want to have these values in a small table witch I can place on screen.
    I already have a program that similar on what you need
    I just slightly edited to your suit
    Give this a try

    ~'J'~
    Attached Files Attached Files
    Last edited by fixo; 2010-02-01 at 10:33 AM. Reason: spell check

  6. #6
    Member
    Join Date
    2009-12
    Posts
    20
    Login to Give a bone
    0

    Smile Re: block and table lisp

    thanks I'm going to try if its working for me.

  7. #7
    Member
    Join Date
    2009-12
    Posts
    20
    Login to Give a bone
    0

    Smile Re: block and table lisp

    Hi Fixo,

    I have tried it and the error
    error: no function definition: VLAX-GET-ACAD-OBJECT

    Is possible for you to explain for each rule in the lisp what it is doing, I new with lisp programming and want to learn how its build up.

    thanks in advance

  8. #8
    I could stop if I wanted to msretenovic's Avatar
    Join Date
    2002-02
    Location
    Galloway, Oh
    Posts
    305
    Login to Give a bone
    0

    Wink Re: block and table lisp

    You will need to run VL-LOAD-COM before running Fixo's code. You can do this easily by place (vl-load-com) on the first line of his file. When the file is loaded, it will run automatically. This loads the VL* functions, and many people have it run at startup so they don't have to worry about it. If it is ran more than once, nothing will happen.

  9. #9
    Member
    Join Date
    2009-12
    Posts
    20
    Login to Give a bone
    0

    Smile Re: block and table lisp

    Quote Originally Posted by msretenovic View Post
    You will need to run VL-LOAD-COM before running Fixo's code. You can do this easily by place (vl-load-com) on the first line of his file. When the file is loaded, it will run automatically. This loads the VL* functions, and many people have it run at startup so they don't have to worry about it. If it is ran more than once, nothing will happen.
    Ok thanks,

    Now its working,

    I don't now if you can help me with the code, what I want to do is to make a sum of each different attributes, or even more complicated a compleet formula, so I want to have a total for GKW, FLOW and KPA seperate., even when the values of the GWK, FLOW and KPA are not the same for each different block.

  10. #10
    AUGI Addict fixo's Avatar
    Join Date
    2005-05
    Location
    Pietari, Venäjä
    Posts
    1,269
    Login to Give a bone
    0

    Default Re: block and table lisp

    Quote Originally Posted by john.237249 View Post
    Ok thanks,

    Now its working,

    I don't now if you can help me with the code, what I want to do is to make a sum of each different attributes, or even more complicated a compleet formula, so I want to have a total for GKW, FLOW and KPA seperate., even when the values of the GWK, FLOW and KPA are not the same for each different block.
    Hi, John
    Think better yet you need to create the sample drawing with blocks
    and with populated table with correct result in there
    Then do posting it in an attachment that would also help
    me to write what you exactly need

    ~'J'~

Page 1 of 3 123 LastLast

Similar Threads

  1. lisp table help
    By kevinjorisjacques967722 in forum AutoLISP
    Replies: 27
    Last Post: 2014-10-11, 05:38 AM
  2. Block Table inside the Block Editor
    By Wish List System in forum AutoCAD Wish List
    Replies: 3
    Last Post: 2013-11-12, 04:56 PM
  3. Curve Table Lisp Routine
    By julie.206712 in forum AutoLISP
    Replies: 7
    Last Post: 2013-08-20, 02:40 PM
  4. Select & entget object information in XREF and block-in-block with Lisp
    By Wish List System in forum AutoCAD Wish List
    Replies: 0
    Last Post: 2012-11-14, 09:11 AM
  5. Block Attribute Table Values Dont' Appear in Block
    By stusic in forum Dynamic Blocks - Technical
    Replies: 2
    Last Post: 2011-12-27, 02:58 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
  •