Announcement

Collapse
No announcement yet.

Array Formula referencing (2) parameters?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Array Formula referencing (2) parameters?

    Is it possible to reference (2) parameters in an array formula? See attached for what I wan't to happen and for the error message why Revit won't let it happen. Basically I'm trying to drive an array count with a length and spacing parameter. In case it matters, this family is a pvc pipe which would be strapped to a wall. Any understanding would be appreciated.
    Thanks in advance!
    Attached Files

    #2
    Check to see if your different size types are making the formula invalid mathematically.
    Developer at Anguleris BIMsmith Marketplace.
    Previously at Sumex Design for ARCAT.com

    Comment


      #3
      You can have as many parameters in the formula as you want as long as the units work out. The error is pointing to the 6" type, so you'll need to look there to see what the issue is. If I had to guess I'd say maybe your spacing is set to 0 in that type. You might need to clear the formula to change types, set the spacing for all types to a non-zero number, and then put the formula back in.
      It's also a good idea to add a second "array check" parameter that actually drives the array instead of using the length/spacing directly. This would just be =if(array<2, 2, array) to keep your array from breaking.
      Last edited by chris.macko; March 29, 2017, 02:22 PM.

      Comment


        #4
        Andrew K, After reading your reply I immediately jumped back into that family as I thought/think that may have been the issue as I did forget to set the "Array Spacing" parameter values in the other types I had created. So I adjusted those values and ended up with the same error message except instead of referencing the specific type (8"Ø) that was creating the error Revit just said type ""... So long story short, I ended up deleting all types other than the initial (4"Ø) I created. The formula worked fine in the 4" type so I just re-created the other types and everything was good. I think Revit was "craking out" a little bit but your response was spot on and pointed me in the right direction.

        Comment


          #5
          Got it Chris! Thanks much for the additional bit on the "array check".

          Comment


            #6
            I can only make the panel width vary with some constant louvers spacing by having the formula for the number of Louvers to be the louverswidth (panel width - 250mm )divide by the spacing. but in the case that the width cant be divide nicely. then the spacing will slightly differ from what i want. (For example, if the panel width is 1000mm, while spacing is 80mm. the formula will turn out to give me 9 louvers with 90mm c/c spacing) I need to have the constant spacing. All the leftover dimension should go to start and end as shown in photo. Can anyone help on how to set the formula?
            Attached Files

            Comment


              #7
              You’ll need to do a check on the array. Multiple the array by the spacing and check it against the length. Adjust the array up or down as needed. Then take the new array value and, again multiply it by the spacing but this time subtract that value from your available length and divide by 2. This is what you’ll use at either (probably not both) sides of the array to get it centered.


              Sent from my iPhone using Tapatalk
              Greg McDowell Jr
              about.me/GMcDowellJr

              Comment

              Related Topics

              Collapse

              Working...
              X