Hi everyone,
I am trying to learn Dynamo to do a parametric pattern.
However, when I type the parameter name and connect to the name box, it says
“Warning: Element.SetParameterByName operation failed.
unitType is an invalid unit type. See UnitUtils.IsValidUnitType() and UnitUtils.GetValidUnitTypes().
Parameter name: unitType”
I think it’s because you are trying to write values of an “instance” parameter to a list of family “types”.
So try to place a “FamilyInstance.ByFamilyType” node between your “All Elements of Family Type” and “Element.SetParameterByName” nodes.
I think you can forget my first comment. Other than that, I’m afraid I can’t help you because I don’t quite understand the error on your first picture. Maybe someone else can help. Good luck.
Or you can generate a lengths variable and assign it to “setParameter by name” and then equate the normalization variable with it in currte pattern base.
I have the same problem. I´ve seen in tutorials that they make a python code to set parameter by name but they dont show the code. If someone coul please share that python code would be amazing