Give dynamic array distance a variable length

Give dynamic array distance a variable length

ohalloba
Explorer Explorer
5,591 Views
14 Replies
Message 1 of 15

Give dynamic array distance a variable length

ohalloba
Explorer
Explorer

Hello everyone, 

 

I'm trying to create a "bifold glass door" dynamic block that can be arrayed, but the door can also be adjusted to different sizes and still be arrayed while being attached. When I use an array it only allows me to pick a static distance. I was wondering if it was possible to change that static distance to a variable depending on the glass door size.  Thanks! 

0 Likes
Accepted solutions (1)
5,592 Views
14 Replies
Replies (14)
Message 2 of 15

j.palmeL29YX
Mentor
Mentor

Post your block please. 

Jürgen Palme
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature

0 Likes
Message 3 of 15

ohalloba
Explorer
Explorer

2e5d6eaab55b0e937605724bb3cc00c2.png

f34ee72863444fda33f4727d78b05811.png

  I'm trying to make it so no matter the size you stretch it, the windows will always array the length of the window. I'm relatively new to dynamic blocks.

0 Likes
Message 4 of 15

j.palmeL29YX
Mentor
Mentor

Are you looking for something like >>this<<

 

 

 

Jürgen Palme
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature

Message 5 of 15

ohalloba
Explorer
Explorer

Thank you so much for creating the block, but I'd love to know the steps for the future if it's not a bother. Thanks again.  

 

0 Likes
Message 6 of 15

j.palmeL29YX
Mentor
Mentor
Accepted solution

@ohalloba wrote:

I'd love to know the steps for the future if it's not a bother.   

 


 

My first attempt above was not well designed, therefore you find here attached an improved version. 

The main principle: As far as I know it is not possible to modify the source object(s)  of an array inside a dynamic block. But in the current case you can create a dynamic array and hide the unwanted parts of the middle line behind a wipeout. You can follow the detailed steps in >>this video<<

(I'm afraid it is not easy to understand. If you have further questions, ask again).

 

Hint: In the current version the user must ensure that the Length overall must be greater than the 2*Width (or the Width must be smaller than Legth/2. In a later version this can be included in the block definition).

 

 

 

 

 

 

 

Jürgen Palme
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature

Message 7 of 15

ohalloba
Explorer
Explorer

Amazing video and I'm following along nicely, but at the part where we have to array the 2 rectangles on a path, I get an error saying "A dimensional constraint or user variable with an expression has been set to a numerical value." And deletes the "Width" dimension on the top, but I'm following your instructions step by step.  

0 Likes
Message 8 of 15

ohalloba
Explorer
Explorer

before arraybefore arrayAfter arrayAfter arrayas I exit arrayas I exit array

 

When I copy and paste your block into my drawing that message pops up again and ruins the block

Message 9 of 15

j.palmeL29YX
Mentor
Mentor

At the latest before creating the array set the system variable DELOBJ to 0. 

(After creating the array you can set DELOBJ back to the value of your need).

Try if that helps and let me know. (I'm not yet sure why that "When I copy and paste your block into my drawing that message pops up again and ruins the block" happens. )

Jürgen Palme
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature

Message 10 of 15

ohalloba
Explorer
Explorer

I got everything working, thank you so much!

0 Likes
Message 11 of 15

heretic2k
Community Visitor
Community Visitor

You can use constraint parameters to achieve your ideas

0 Likes
Message 12 of 15

heretic2k
Community Visitor
Community Visitor

You can use constraint parameters to achieve your ideas

0 Likes
Message 13 of 15

j.palmeL29YX
Mentor
Mentor

@heretic2k 

Obviously this suggestion refers to another thread ( ?).
But regardless of that, allow me a few hints:
- You forgot a coinzident constraint. 

 

 

 


Now it works.

 

 

- Next: I'd suggest to constrain as much as possible using geometrical constraints. As example: you can (and should) delete all the dimensional parameters, which depend on W (d1, d3, d5, d6, d7). Use "Equal" constraints instead. The same for all dimensions depending on T.

 

- Additional: For all those dimensions that may be necessary but should not be controlled by the user, don't use dimensional constraint Parameters (bcparameter command). Use instead suitable dimensional constraints (one of the dc... commands). (In the current example we don't need such dimensions)

 

Bonus: For fun I added an angular constraint to open/close the door.

 

 

My 2ct only

Jürgen Palme
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature

0 Likes
Message 14 of 15

laurenyy
Community Visitor
Community Visitor

Thank you for the video.  I am stuck at the part where you enter "floor" for d2 dimension.  Where is the "floor" variable defined? 

0 Likes
Message 15 of 15

j.palmeL29YX
Mentor
Mentor

floor is a mathematical function which rounds down a numerical value to the next Integer. 

 

Snip from the help: 

 

floor.png

Jürgen Palme
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature