Hi,
is there a way to get the data type (i.e. integer, float, string/text, etc) of a given parameter either of system or component family?
I’m trying to export data to sqlite and i need to prepare the string data to add single quotes.
I managed to do so in python with the repr() function but I need to tell manually which parameters are to be converted in strings.
I wonder if there is a way to get the data types expected in revit for each parameter to use it as a comparison list to get indices.
If that’s not possible then I thought to loop through the parameter values of my list and check in python with various built in functions (i.e. isinstance(x, str) etc).
Hi @Alban_de_Chasteigner,
I come back to you as I tried to use your node Element Parameters Parameter but I’m not sure about how to ensure matching Name VS StorageType.
I’m a beginner in Dynamo so my understanding of sorting lists may be poor.
I tried to sort the parameter names alphabetically and now I’m trying to match the StorageType in the same order. If I performed the sorting correctly (so showing the real connection parameter-storagetype) I’m puzzled that for instance for BaseFinish parameter Revit is storing the data as double…
Please see the image below and attached graph.
Thanks again for your help. GetParamNamesNDataTypes_RoomsCategory.dyn (23.9 KB)
However, it is not possible to find the Family(element) for system families. But it is possible to retrieve the name of the base family with the Element GetLoadableFamily node.
How to understand the principle of revit logic? when we use “e.Name” block, how can it knows we are looking for the “Type” name, instead of other names?