Are you looking for the ElementId of the parameter or the element?
You can modify the Clockwork node to return the Id as well as the name and category.
A good way to learn Python is to just look at other people’s code and try to modify it in small pieces to get what you want.
Here is the code from Document.ProjectParameters.
You can see in line 19 we take the Name of each Key and append it to the list we named params.
You basically want to do this exact same process but with the Id instead of name. All you need to do is create a new empty list for our Ids after line 16. ids = []
Then we can duplicate the line for getting names and change the pieces we need to instead append the Id to list ids that we just created. ids.append(iterator.Key.Id)
Then just be sure to add our list ids to the output at the end of the code.
I would take the Python script out of the custom node and insert it in its own Python script node, that way you can see what error you are getting when running the code:
Side note… I think you may have to close out Dynamo and the Revit document, and reopen both.
@Nick_Boyts Maybe you could see if you can reproduce the same thing, but when I was playing around with this, if I ran the code with an error in it, neither the Clockwork Document.ProjectParameters node nor the edited Python code would work until closing and reopening both the Dynamo file and the Revit document. The Python code would return an error saying “The managed object is not valid” and the Clockwork node would return all nulls.
Using Element.ByID is giving you the parameter element of the parameter “Element ID”, so you are getting your parameter. Run the element through an Element.Name or a Parameter.Name node and you can see the name to verify. What is the error you are getting on the FilterRule.ByRuleType node?
Actually something in this isn’t working. Maybe something to do with how the Element.ByID node works, but the returned object type is an UnknownElement rather than a Parameter.
how can I get the parameter entity itself by from the ID of it? for example builtinparameters/project parameters/global parameters. I want to ask properties of the parameters later with OOTB nodes