Revit Architecture Forum
Welcome to Autodesk’s Revit Architecture Forums. Share your knowledge, ask questions, and explore popular Revit Architecture topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Parametric Cabinet with max door width constraint.

9 REPLIES 9
SOLVED
Reply
Message 1 of 10
TAZ-ZA
1418 Views, 9 Replies

Parametric Cabinet with max door width constraint.

TAZ-ZA
Contributor
Contributor

Hello - please help!

 

I’m trying to create a parametric cabinet which has the following constraints:

 

  1. Height, width and depth all parametric.
  2. Cabinet doors to be a max of 450mm
  3. If width of cabinet exceeds a multiple of 450mm then doors must divide equally by the width.

 

E.g. if the cabinet width is 1200mm then each door would be 400mm wide.

 

So far, I can flex height, width and depth. Cabinet doors also flex, but exceed desired max 450mm width.

 

Any advice would be fantastic. I’m more than happy to share with the community if I can figure it out.

 

Thank you.

0 Likes

Parametric Cabinet with max door width constraint.

Hello - please help!

 

I’m trying to create a parametric cabinet which has the following constraints:

 

  1. Height, width and depth all parametric.
  2. Cabinet doors to be a max of 450mm
  3. If width of cabinet exceeds a multiple of 450mm then doors must divide equally by the width.

 

E.g. if the cabinet width is 1200mm then each door would be 400mm wide.

 

So far, I can flex height, width and depth. Cabinet doors also flex, but exceed desired max 450mm width.

 

Any advice would be fantastic. I’m more than happy to share with the community if I can figure it out.

 

Thank you.

9 REPLIES 9
Message 2 of 10
ToanDN
in reply to: TAZ-ZA

ToanDN
Consultant
Consultant

Add a formula to control the Array Integer parameter: = roundup (Width/450)

0 Likes

Add a formula to control the Array Integer parameter: = roundup (Width/450)

Message 3 of 10
RDAOU
in reply to: TAZ-ZA

RDAOU
Mentor
Mentor
Accepted solution

@TAZ-ZA 

 

  1. You model the door in a separate family and nest it in (associate with parameter align and lock ...etc) where the Panel Width = if(P1, 450, (Cabinet_Width - Joints) / Array) 
  2. Then you need to place 1 instance for when the width is 450
    • give this panel a visibility parameter P1 = or(Width=450, Width<450)
  3. Then place a another instance (the one you will array).
    • Give this panel a visibility parameter P2 = not(P1)
    • Array, label and Lock it as needed
    • Set the Array = if(P2, roundup(Width/450), 2)

 

Alternatively, and if you are working with 1 to 3 panels, it might be easier and lighter to just nest 3 types of panels (single/double/triple door) and either control these using Y/N per cabinet type or using a Family<Type> label controlled by cabinet width

 

 

YOUTUBE | BIM | COMPUTATIONAL DESIGN | PARAMETRIC DESIGN | GENERATIVE DESIGN | VISUAL PROGRAMMING
If you find this reply helpful kindly hit the LIKE BUTTON and if applicable please ACCEPT AS SOLUTION


0 Likes

@TAZ-ZA 

 

  1. You model the door in a separate family and nest it in (associate with parameter align and lock ...etc) where the Panel Width = if(P1, 450, (Cabinet_Width - Joints) / Array) 
  2. Then you need to place 1 instance for when the width is 450
    • give this panel a visibility parameter P1 = or(Width=450, Width<450)
  3. Then place a another instance (the one you will array).
    • Give this panel a visibility parameter P2 = not(P1)
    • Array, label and Lock it as needed
    • Set the Array = if(P2, roundup(Width/450), 2)

 

Alternatively, and if you are working with 1 to 3 panels, it might be easier and lighter to just nest 3 types of panels (single/double/triple door) and either control these using Y/N per cabinet type or using a Family<Type> label controlled by cabinet width

 

 

YOUTUBE | BIM | COMPUTATIONAL DESIGN | PARAMETRIC DESIGN | GENERATIVE DESIGN | VISUAL PROGRAMMING
If you find this reply helpful kindly hit the LIKE BUTTON and if applicable please ACCEPT AS SOLUTION


Message 4 of 10
TAZ-ZA
in reply to: RDAOU

TAZ-ZA
Contributor
Contributor

Thank you @RDAOU and @ToanDN. I couldn’t make that work for me unfortunately.

I just want to clarify the steps I’ve taken.

  1. Modelled a door in a separate family making the width parameter instance based before loading it into the carcass/shell family.
  2. Locked door to reference planes in the carcass/shell family and made door width = Width/Array
  3. I applied a visibility parameter to that door (Yes/No, Visibility) - (P1) = and(Width=450, Width<450)
  4. I placed another instance of the door in the same place as the first door and locked it to reference planes.
  5. I applied visibility parameter (Yes/No, Visibility) - (P2) = and(Width=450, Width<450)
  6. I arrayed the second door and placed the following parameter to the array: if(P2, roundup(Width/450), 2)

When I flex the width, the door just stretches and overlaps the first door.

0 Likes

Thank you @RDAOU and @ToanDN. I couldn’t make that work for me unfortunately.

I just want to clarify the steps I’ve taken.

  1. Modelled a door in a separate family making the width parameter instance based before loading it into the carcass/shell family.
  2. Locked door to reference planes in the carcass/shell family and made door width = Width/Array
  3. I applied a visibility parameter to that door (Yes/No, Visibility) - (P1) = and(Width=450, Width<450)
  4. I placed another instance of the door in the same place as the first door and locked it to reference planes.
  5. I applied visibility parameter (Yes/No, Visibility) - (P2) = and(Width=450, Width<450)
  6. I arrayed the second door and placed the following parameter to the array: if(P2, roundup(Width/450), 2)

When I flex the width, the door just stretches and overlaps the first door.

Message 5 of 10
RDAOU
in reply to: TAZ-ZA

RDAOU
Mentor
Mentor

@TAZ-ZA 

 

Post the family you have now ... 

 

 

YOUTUBE | BIM | COMPUTATIONAL DESIGN | PARAMETRIC DESIGN | GENERATIVE DESIGN | VISUAL PROGRAMMING
If you find this reply helpful kindly hit the LIKE BUTTON and if applicable please ACCEPT AS SOLUTION


0 Likes

@TAZ-ZA 

 

Post the family you have now ... 

 

 

YOUTUBE | BIM | COMPUTATIONAL DESIGN | PARAMETRIC DESIGN | GENERATIVE DESIGN | VISUAL PROGRAMMING
If you find this reply helpful kindly hit the LIKE BUTTON and if applicable please ACCEPT AS SOLUTION


Message 6 of 10
TAZ-ZA
in reply to: RDAOU

TAZ-ZA
Contributor
Contributor

@RDAOU - Attached.

0 Likes

@RDAOU - Attached.

Message 7 of 10
TAZ-ZA
in reply to: TAZ-ZA

TAZ-ZA
Contributor
Contributor

*DELETED*

0 Likes

*DELETED*

Message 8 of 10
RDAOU
in reply to: TAZ-ZA

RDAOU
Mentor
Mentor
Accepted solution

@TAZ-ZA 

 

 

  • P1 formula should be or(Width = 450 mm, Width < 450 mm)
  • The formula you entered in P2 is wrong ...should be not(P1)
  • And you need to lock the array properly at start and end
  • And Door width formula needs to be if(P1, Width, Width / Array)

 

RDAOU_0-1644588195258.png

 

 

Fix Cabinet.gif

 

YOUTUBE | BIM | COMPUTATIONAL DESIGN | PARAMETRIC DESIGN | GENERATIVE DESIGN | VISUAL PROGRAMMING
If you find this reply helpful kindly hit the LIKE BUTTON and if applicable please ACCEPT AS SOLUTION


@TAZ-ZA 

 

 

  • P1 formula should be or(Width = 450 mm, Width < 450 mm)
  • The formula you entered in P2 is wrong ...should be not(P1)
  • And you need to lock the array properly at start and end
  • And Door width formula needs to be if(P1, Width, Width / Array)

 

RDAOU_0-1644588195258.png

 

 

Fix Cabinet.gif

 

YOUTUBE | BIM | COMPUTATIONAL DESIGN | PARAMETRIC DESIGN | GENERATIVE DESIGN | VISUAL PROGRAMMING
If you find this reply helpful kindly hit the LIKE BUTTON and if applicable please ACCEPT AS SOLUTION


Message 9 of 10
TAZ-ZA
in reply to: RDAOU

TAZ-ZA
Contributor
Contributor
You're a saint. Thank you so much.
0 Likes

You're a saint. Thank you so much.
Message 10 of 10
RDAOU
in reply to: TAZ-ZA

RDAOU
Mentor
Mentor

@TAZ-ZA 

 

You are welcome...other things you need to fix

  1. The door doesn't need to be casework...you can change its category to generic model
  2. The Height, Width, Depth in the door you can change to Type parameter (you need instance only if you are using shared components)
  3. You also need to Associate the Height of the door to that of the Cabinet

 

See attached 2022 revised

 

 

YOUTUBE | BIM | COMPUTATIONAL DESIGN | PARAMETRIC DESIGN | GENERATIVE DESIGN | VISUAL PROGRAMMING
If you find this reply helpful kindly hit the LIKE BUTTON and if applicable please ACCEPT AS SOLUTION


0 Likes

@TAZ-ZA 

 

You are welcome...other things you need to fix

  1. The door doesn't need to be casework...you can change its category to generic model
  2. The Height, Width, Depth in the door you can change to Type parameter (you need instance only if you are using shared components)
  3. You also need to Associate the Height of the door to that of the Cabinet

 

See attached 2022 revised

 

 

YOUTUBE | BIM | COMPUTATIONAL DESIGN | PARAMETRIC DESIGN | GENERATIVE DESIGN | VISUAL PROGRAMMING
If you find this reply helpful kindly hit the LIKE BUTTON and if applicable please ACCEPT AS SOLUTION


Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report