Filtering by parameter and getting the ID of that element


I am trying to copy views from one model to another. I am filtering the views that I need to extract from the File Path. I need to filter by a project parameter that I created and getting the ID of that object.
I was able to filter and create a list were I have the object with the parameter and their ID. But when I filtered by the project parameter with boolmask I get true to the project parameter, but false to the ID. And I need the information of the ID not the parameter.

I attached a picture so it s clear.

1 Like

@dcairopresepi ,

You can use dictionary methode…



1 Like

you can get the firstitem after transpose, then use if in dynamo to replace the ID…I am not near my pc now

Like this maybe

1 Like

So i am trying this, I first try to filter the views by the parameter i created. And when I used the dictionary by keys it is not working.

1 Like

I think you’re overcomplicating it. The parameter values and Ids are coming from the same list of elements, so there’s no need to filter them together. You can either check the parameter and then filter the Ids directly, or filter the element based on the parameter and then return the element Id after the filter.