+ Reply to Thread
Results 1 to 7 of 7
  1. #1
    Forum Newbie
    Using
    AutoCAD 2015
    Join Date
    Sep 2016
    Posts
    3

    Default Change block color through block table

    Registered forum members do not see this ad.

    Hi everybody,
    I wanted to know if there is a way I can control the layer a block is in through the block table, so if I change a set of parameters through the table, one of them could be "Layer" and that way I can change it appereance. I want to avoid visibility parameters, as there are too many permutations of blocks for that.
    Thanks for the help in advance!

  2. #2
    Luminous Being RobDraw's Avatar
    Using
    MEP 2017
    Join Date
    Apr 2007
    Location
    Connecticut, USA
    Posts
    5,161

    Default

    What is the block table? It sounds interesting. Something custom or an add-on of some sort?

    With it being so easy to change the layer that a block is on, I think you are asking about something more involved than just changing the assigned layer of a particular block.

    Visibility parameters makes it sound like you are working with a dynamic block and that property has nothing to do with layers, AFIK.
    Drafting is a breeze.

  3. #3
    Forum Newbie
    Using
    AutoCAD 2015
    Join Date
    Sep 2016
    Posts
    3

    Default What I have so far

    butaca.dwg
    I would like this block to be the ultimate chair placement planner for cinemas and the like, so far I have managed to change the dimensions of different parts through a block table, I would like to use this tool to also change the layer of the block, so I get a visual queue of the different chairs used in the room.
    What I would also like:
    - maintain an align paramenter centered when changing width (necessary for adapting to the arcs of the "steps" of the room. I think that it´s staying in the same position relative to the origin of the block
    - Be able to "repeat" the block (like in an array) and change each instance as I see fit, and when I change the width of an instance, the rest of the array accomodates to make room for it.

    Christmass wish:
    That given a length for this "array" (I don´t know if its possible to do it with that tool, it´s very restrictive) the block accomodates the chairs within this distance changing the widths as needed (for example, give a length of 65", it places two 23" chairs and a 22" chair to get the best approximation possible to the length) I´m doing it manually right now, very time consuming as there are theaters with many row widths.

    Thanks for your quick response!

  4. #4
    Luminous Being RobDraw's Avatar
    Using
    MEP 2017
    Join Date
    Apr 2007
    Location
    Connecticut, USA
    Posts
    5,161

    Default

    Good explanation. I can't wait to take a look at it, tomorrow. I'm sure someone here has done something like that before and will be able to help you out.
    Drafting is a breeze.

  5. #5
    Luminous Being
    Using
    Civil 3D 2016
    Join Date
    Dec 2005
    Location
    GEELONG AUSTRALIA
    Posts
    9,727

    Default

    It may be better to not use a dynamic block rather take the length divide / 23 check remainder and add a 22 21 19 etc to make it work. Just me as I dont play with dynamic blocks much. Chairs on a curve come to mind.

    The other way would be to add a second chair to the block which has its own sizes lookup. The 1st chair has an extra dynamic which is a repeat function as you drag. You could then probably add a lisp control pick point1 point2 all done. You would probably need a left and right version.

    Here is a good sample dwg that has auto repeat in it, plus other restraints.
    Attached Images
    Attached Files
    A man who never made mistakes never made anything

  6. #6
    Forum Newbie
    Using
    AutoCAD 2015
    Join Date
    Sep 2016
    Posts
    3

    Default

    @Bigal:
    The idea of a second chair is a nice one, I want to avoid the handles as much as I can, so I think i´ll keep the size as it is. How can yo make the repeat action to make a curve? maybe an action for straight line and one for curves? any idea about the centered align parameter? nice blocks you attached... parking lots? the repeat action is an array, it´s great for this application, because the width of the parking place should be always the same. I guess that if the block is simple enough it shouldn´t be so cumbersome to "stack" a couple of instances to complete rows, but it would still be an iterative process to solve each row, for example, If you wanted to chain handicapped spaces with normal ones on a single block (I know, everybody tells me I should keep blocks simple, but the path of learning and mastering is a thorny one). Thanks for the example, I think I learned a thing or two from it.

    Seeing the above example from BIGAL, I think I would think in advance and make the chairs "share" armrests, so in the future I can extract the info to make material calculations a breeze,
    so far I´ve got the following: IOI wich would repeat IOIIOIIOIIOI, even when I overlap an armrest, I will change the block to IOIOI with a repeat on the first seat and middle armrest, so it repeats IOIOIOIOIOI
    @RobDraw
    Thanks on any improvement for the dynamic block, I appreciate the effort!

  7. #7
    Luminous Being
    Using
    Civil 3D 2016
    Join Date
    Dec 2005
    Location
    GEELONG AUSTRALIA
    Posts
    9,727

    Default

    Registered forum members do not see this ad.

    Sounds like your heading in right direction. The lisp to work out a left & x mids & right is pretty straight forward and as your ends have a size variation will help. You can use 1 dynamic block and adjust size rather than have multiple blocks for each size. Lee-mac has good dynamic block routines and they are very simple to understand. So can be added to a repeating pattern.
    A man who never made mistakes never made anything

Similar Threads

  1. Block Will Not Change Color
    By ACV in forum AutoCAD Drawing Management & Output
    Replies: 5
    Last Post: 9th Aug 2016, 02:17 am
  2. Change color of text on an attributed block
    By Efeezy in forum AutoLISP, Visual LISP & DCL
    Replies: 2
    Last Post: 20th Sep 2015, 07:19 pm
  3. How to change Object properties(color, lineweight, etc.) in a block
    By samcoozy in forum AutoCAD 2D Drafting, Object Properties & Interface
    Replies: 7
    Last Post: 21st Feb 2013, 05:06 am
  4. Block attribute change within a table...
    By Seneb in forum AutoCAD 2D Drafting, Object Properties & Interface
    Replies: 20
    Last Post: 10th Feb 2009, 07:11 pm
  5. how to change a layer color in a block made out several blocks
    By firsrate_caduser in forum AutoCAD General
    Replies: 6
    Last Post: 16th Nov 2006, 06:25 pm

Tags for this Thread

Bookmarks

Posting Permissions

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