Shared parameters


#1

Is there a way to access shared parameters?

Thanks!


#2

Access Shared Parameters in what way?

If you mean ‘Retrieve’ parameter data into Dynamo from families within project that have Shared Parameters, then Yes.


#3

Danny - thanks for reply. Yes, I want to get the Shared Parameters of families from a project.

I could not find any node for that. “Get Family Parameter” is not retrieving the Shared Parameter.

Please suggest how. Thanks.


#4

adrian, in dynamo is a difference between accessing type parameters and instance parameters.

if you want to access an instance parameter you will go with “Element.GetParameterValueByName” where element is the instance, parameterName is the name of the instance parameter.

this is working for any kind of parameter - no matter if sharing or not.

if you want to access a type parameter you have the Get Family Parameter" node. it works after 1st run and you have connected it to a family instance. in the pull down you may select the parameters name.

another method is a custom node “GetTypeParameter.FrmFamilyInstance” downloadable from package manager.

there you just have to select a family instance type in the (shared)parameters name and voila you get the value.

should be working for any family.

 


#5

Peter - thanks for reply.

I know about the difference between instance and type parameters.

I’m not able to “pull” the Shared Parameters (both names and values, and I want both when I query an family instance). The 'type" and “instance” are showing up well, I cannot query the shared once.

What I’m trying to do is the following: have a family with certain Shared Parameters. Then once the family is loaded in Revit, I want to

extract all that data from the Shared Parameters and do math operations with them. In this particular case, I’ve built a parametric downspout family, I want to extract all the data

for materials (area, length, weight, etc. - so I can create a comprehensive bill of materials, including costs associated with transportation). Then I want to link the downspouts with the

roof drainage system. The final product will be an intelligent downspout system that will tell how many and what type (diameter) I need for a specific roof and project location (historical rainfall data will be also used for calculations)

Once the downspouts are placed in Revit the schedule/bill of material will be populated automatically.

So long story short: I want to get the Shared Parameters list, then able to extract their values and then play with those values in formulas.

Part of these things can be done inside Revit, without Dynamo help, but I’m exploring the limits of Dynamo.SHARED_PARAM_1_red

 

Thanks for your help!

 


#6

It sounds like we are clear on what you are trying to do. Have you tried developing a Dynamo definition? If so please attach and we can comment to see why it is not working.


#7

Edwin - I just pulled the nodes that are related to parameters, see what the output is when I select the family. None of the nodes return Shared ParametersSHARED_PARAM_2. What I’m missing? thanks.

 


#8

Hi Adrian,

Could you try the following - feed your shared parameter’s name as a string into the “Get family Instance Parameter Value”.

I think that the confusion is coming from the fact that you’re still using Dynamo 0.63. Some of the nodes had to be renamed in later versions to make them integrate better with the new Design Script language. For example the “Get family Instance Parameter Value” was renamed to “Element.GetParameterValueByName” node as you can see below:

2014-10-09_095024

I’d recommend to try it for yourself and upgrade to the latest version.

You could get family type parameters in a similar manner:

2014-10-09_100535


#9

Dimitar - thanks for your reply. This is working, however my hurdle was to “query” and “extract” the names + values of a Shared Parameters automatically using Dynamo.

Yes, when I select an instance in Revit, the Properties windows gets populated with the Shared Parameters names and their values and I can pass the name via a string - but I was trying to figure out an automated

process using Dynamo to query + extract that info, then further feeding that into formulas/calculations. Thanks again for your feedback/comments.


#10

Hi Adrian,

Have you managed to sort your issue?

I did a few tests in Dynamo (0.7.2) I am able to Extract Type/Instance shared parameter data and then feed my own inputted dimension through nodes in Dynamo.

Is the images below something you are after? I highlighted the box in the image because I use metric mm in my project and the transfer from Dynamo to Revit is Feet. If you want to adjust established formulas, I suggest you create a constraint parameter, it is easier to work with just 1 number being fed through from Dynamo than a whole formula back into Revit.

C01 C02


#11

Hi there.
Going deep in that direction, let me ask: Let’s suppose an instance of “Floor: Structural” (Revit 2016) of type “Generic Floor - 400”. The thickness of this structural floor is automatically set by its type (400mm). This property is composed by a layer of materials. On editing Generic Floor - 400mm type, press Edit… on Construction/Structure and then you’ll see the definition of each layer.
The question is: how to achieve each of those layers within Dynamo?