Autodesk.Revit.DB.Parameter to Revit.Elements.Parameter

How can I wrap DB.Parameter to Revit.Elements.Parmater?

Running this:

import clr

clr.AddReference("RevitNodes")
import Revit
clr.ImportExtensions(Revit.Elements)
from Revit.Elements import ElementWrapper

parameter = IN[0]
OUT = Revit.Elements.ElementWrapper.ToDSType(parameter, True)

Causes this:

Warning: IronPythonEvaluator.EvaluateIronPythonScript operation failed. 
Traceback (most recent call last):
File "<string>", line 9, in <module>
TypeError: expected Element, got Parameter
1 Like

did you find a solution? I am wanting to get the corresponding parameter ID of those parameter Elements but not the ID of the element parameter

I wish you good health. In the previous python node, you must perform an operation with the code that you wrote directly with the element itself, and then get its parameter. The value will be readable.