Creating script that takes the top level point and copy it to family shared parameter

is it possible to create a dynamo script that copy the top point survey value of an element (manhole cover in my case) to shared parameter family “TopLevel”?



i’ve created a manhole family with a specific tag for it which shows those parameter:
#manhole number
Top Level
Invert Level
Height
Diameter

everything is worked automatically beside the TopLevel parameter which i need to enter manually.

Yes. What have you tried so far?

Is the Top Level not just the Invert Level plus some depth/thickness? Can you just calculate it?

yes, the top level is Invert Level + Depth.

Im looking for a script that will enter the toplevel value to all manhole in the model instead of me typing manually the value for each manhole family.
I didnt started writing the script yet because im new to dynamo, so im first want to know with which nodes to use in the script.

If you want to learn Dynamo, start with the Dynamo Primer. It would give you examples and tutorials to learn all the basics. The forum is also a good place to learn common tasks - like writing values to parameters. Try looking through some similar topics to get some ideas.

You’ll need to show some effort before others start giving you solutions.
How to get help on the Dynamo forums - FAQ - Dynamo

i succeed to do it but i need one more thing


how can i select multiple family types and not just one? can i define to select all families of plumbing fixture category the their family name begins with “xxx”?

Sure. You have a few options depending on how you want to control what’s selected or not. A common process is to use Categories and All Elements of Category to retrieve all instances of a given category. You can then filter those instances by parameters like Family or Type. You could also provide a list of Family Type names using your current process instead of using a selection node that only provides one value. There are also similar ways to get Family Types from a Family or all Families of category through Dynamo. It all just depends on what you actually need.

I’d recommend trying both of these options and seeing where that gets you. Searching the library or using Node Autocomplete can be helpful when looking for certain functions or relationships.