let’s say we have one family instance populated with values, than we place a new instance of that type and we want to copy all parameter values (likely to be instance parameters only) from one to the other. Is there a direct way to accomplish this with get and set parameter value by name?
and what if we want to copy all parameters from one list of instances to another list of new instances?
Thanks John, your solution got me part of the way. But I don’t see how to copy All parameters from Multiple elements with this method.
I really want to take a Two equal length lists of elements, and copy all instance parameters from one list of elements to the other. I’m sure this should be easy in Dynamo… but I just can’t crack it myself at the moment.
I also think that Dimitar’s code below could almost get me there, but I can’t see how to flip this around and feed a complete list of instance parameters to the SetParameterByName code block (copied from other thread):
Hi Neil,
That should be doable with some replication guides. Have a look at the below example:
You can extract all the instance parameters of that element with the “Element.Parameters” node. That will give you parameter elements, so you’ll have to extract the name of the parameter from that with either “Element.Name” or with some string management. Once you have those, you should be able to proceed as usual with the Get/Set nodes.
Some problems that I see with this work flow is that some of the parameters are read-only and that will lead to a few errors. You might also get a lot of duplicate mark errors.
You can omit the DS lacing by using one of the list combinators like “List.Combine”
Since it’s imperative to filter out read-only parameters, I added a new node for that purpose to package Clockwork (up on the package manager now). Here’s a sample workflow how you would propagate all writable instance parameters of a given family instance to all other placed instances of the same type. (Note that I am using Dynamo 0.7.5 so as to not be affected by the bug Dave mentions above…)
I would have loved to use this parameter query with a 3dView, but since it is a familySystem, it won`t work. What else I could use to select all the 3dview from a Revit document, then filter them…?
Hi Andreas, Element.GetParameterValueByName still has issues in 0.7.5 when it comes to levels, at least in my tests. I updated the GitHub issue. Note how some levels report the name while others report the element ID as an integer (or text string?).
This is still not really working for me. I am trying to take two equal length lists of elements, and copy all of the Instance writeable parameters from one to the other. I would have thought it would be relatively easy in Dynamo Anyway, please see below for my progress. My first problem is that I can only seem to get it to work on one Element at a time, when I try to expand to a list of elements various things don’t work (like the Clockwork ReadOnly check). No doubt this is because I don’t understand how to Map things properly when I have a list of Elements, and sublists of Parameters… The other thing that isn’t working is the GetParameter node - as a workaround to the 0.8 issue, the one I am using successfully gets values as Strings, but obviously this doesn’t really work because I can’t push Length and Yes/No values into the target element (because they are strings).
Hi Luke, you cannot directly pass a list for input port parameterName. You have to use a List.Map node or a series of them to process lists when nodes don’t accept lists (have I said “lists” enough times?!). It would be fantastic to have nodes that accept both; Dynamo would be so much more user friendly.
Anyway, here’s what you need to do I think. In this example I have a list of objects (Rooms) and a list of parameters I want to retrieve. Basically the function just gets more complex and you nest other List.Map nodes as required. Hope I’m explaining this correctly and it helps in some way.
Hello to the Dynamo community. I would appreciate some help with this question, related to this conversation. I have noticed a limitation in “ElementGetParameterValueByName”. It seems to work fine except for those parameters included in the Identity Data group of families, such as “Model”, “Description”, “URL”, “Keynote” and others in that group. Well, that’s exactly what I needed, the Description parameter. I want to write a workflow that gets all the values of the Description parameter of the Specialty Equipment category, and changes the values from lowercase to uppercase. I can do it with other parameters, but when I try with the “Description” parameter (or any other parameter of that group) the script cannot read the values. Is this a limitation of this node? Is there another way to get that value?
EDIT: …and, by the way, how did you guys manage to change your avatar here? I have tried several times to upload an image, but my profile does not update.
Well, thanks to this forum, I learned about the usefulness of custom packages. I loaded “Rythm”, and it contained the 2 nodes that solved the problem that I was describing above. Here I am sharing the solution: Change Description Parameter Text to UpperCase or LowerCase
…and, I don’t know what happened to my previous message. Sorry, it’s my first time here. I was expressing my gratitude to Kulkul for posting a solution to my questions. Thank you very much again.
I am having the same problem here. I want a generic family with 3d text as parameters to obtain the information of the room that it lies within. is this possible?
I tried a few of these methods only to scrap them and start over. I am trying to select the Room Bounding parameter in a wall (for now- eventually certain wall types) and i can grab almost every single other parameter except that one. I am starting to think it is one of those system/default issues that it may be unselectable. Has anyone stumbled on something like this?