By Dennis Collin
When making a family with an Array as a parameter, Revit will not allow a value of less than one. This omission is a much-requested improvement for Revit, but in fact it can be done now with a little application of smoke and mirrors! You can’t actually have an array of one item, but by ‘cheating’ with visibility parameters, formulae and having both a single and arrayed sequence in a family, users can convey the impression that you can!
Consider a detail component, in this case a repeating brick detail family, a brick detail component is loaded into a line base detail family. This element is copied, one element remains as a single component, the other is arrayed and is driven by the length parameter. The number of bricks is just simply the length divided by the individual brick size, in this case 75mm.
To calculate whether a single or multiple brick is displayed, ‘a number of bricks’ parameter is used to drive a conditional IF formula. If the number of bricks is less than 2, Revit will show a single brick, if 2 or more then the multiple brick array will be displayed.
As Revit does not allow an Array value of less than 2 an If statement forces the multiple bricks Qty parameter to remain at 2 elements. However, the visibility of the multiple brick array will be turned off and the Single brick will show instead, courtesy of the simple Not logic operator in the formula field.
With these formulas in place Revit achieves the impossible, the line-based detail family will allow users to draw a line of bricks, but should the number of bricks be edited or stretched resulting in one brick, the multiple bricks disappear, and a single brick appears in its stead.
Komentarai (0 komentarų)