dynamic array: count every piece as 1.

dynamic array: count every piece as 1.

Anonymous
Not applicable
3,655 Views
12 Replies
Message 1 of 13

dynamic array: count every piece as 1.

Anonymous
Not applicable

hello,

 

i want to have an array dynamic block, but i also want them to count each piece from the array as 1 object and not as 1 dynamic block in a data extraction.

 

who can help me?

 

kend regards

0 Likes
Accepted solutions (2)
3,656 Views
12 Replies
Replies (12)
Message 2 of 13

MMcCall402
Mentor
Mentor

Some ideas:

 

If the item(s) being arrayed in the dynamic block is itself a block, then you can run a data extraction on that internal block for a 'count' of those blocks and it will count all instances of that block, both inside the dynamic block array and if the block is inserted as a single block.

 

If the item(s) being arrayed are not a block, you can have the date extraction pull the linear parameter value that controls the array, table the values, add a column with a formula to divide that value by the array distance, then total the column.    Or, you could insert an attribute into the block with a field set to access the value of the linear parameter, divide it by the array distance, then have the data extraction pull that block attribute. (you can make that attribute not visible)

Mark Mccall 
CAD Mangler


EESignature


VHB - Vanasse Hangen Brustlin, Inc.


Linkedin

0 Likes
Message 3 of 13

Anonymous
Not applicable
Hello,
In attachment I have put the dwg of the dynamic blocks with an array.
It's for making a light line, so every piece I need to count as 1 if a make the array.
Kind regards,
Kevin.
0 Likes
Message 4 of 13

MMcCall402
Mentor
Mentor

Try attachment again.

Mark Mccall 
CAD Mangler


EESignature


VHB - Vanasse Hangen Brustlin, Inc.


Linkedin

Message 5 of 13

Anonymous
Not applicable

i have the file in attachment

0 Likes
Message 6 of 13

MMcCall402
Mentor
Mentor
Accepted solution

I see now.

 

Add a new attribute for calculating the array. We'll insert a field as the default value for this attribute to get the value of linear parameter Distance1 and then divide it by the length of the array repeat distance to derive the number of items in the array.

 

Add the new attribute.

In the cell for the Default value right-click and choose Insert Field.

Choose BlockPlaceholder in the Field Names column, Distance1 as the Block reference property, Format as Decimal, Precision 0, then go to the Additional Format and set the conversion factor to 1/1500. (this conversion will be different for each block)

Save the block and run Attsync to resync any insertions of the block with the new block definition.

 

Now run the data extraction to collect this attribute of the block(s)

Mark Mccall 
CAD Mangler


EESignature


VHB - Vanasse Hangen Brustlin, Inc.


Linkedin

Message 7 of 13

Anonymous
Not applicable

hello,

 

i have done everything that was in your previous reply.

but when i did all the steps and try my block, the count stays at 1.

can you please help me with this.

 

thanks in advance,

 

Kevin.

0 Likes
Message 8 of 13

steven-g
Mentor
Mentor
Accepted solution

Your block works just fine here. Did you do a regen after stretching the block

Message 9 of 13

Anonymous
Not applicable

one more question about a dynamic block: when i do an array in the block, can i do it also for the attributes in the block?

0 Likes
Message 10 of 13

steven-g
Mentor
Mentor

Nope, if you try it you'll see it doesn't work, but besides that any attribute within a block has to have a unique tag value or it won't be usable in Autocad.

0 Likes
Message 11 of 13

RBassadone
Contributor
Contributor

Hi there,

I've just picked up this tip and tried it on my drawing, but because my block length [distance] is not a whole number, I'm getting an error code when I try to add the Conversion factor.  It's saying 'the conversion factor is invalid'.

 

What am I doing wrong or is there a way around this?

0 Likes
Message 12 of 13

ojuris
Advisor
Advisor

you can do that in 2 ways:

  1. with formulae
  2. with conversion factor
Message 13 of 13

RBassadone
Contributor
Contributor

You absolute legend! Amazing, thank you 🐵

0 Likes