Duct Auto Set parameters with 2 parameters as filters/conditions

Hi Dynamo Guys,

Can anyone help to correct my script? specially @Kulkul.

I wanted to select all the duct in my Model and set a parameter values automatically but there are some constraints or conditions like i.e.

Only the Duct size ranging from 100mm - 400mm and only with the Parameter values of LP (“LP” is a shared parameter) shall have or shall be set to have an auto value of 400LP ("400LP is a Duct Pressure is my Duct classification).

I Have created my script but I cant figure out whats the best way if I use list.join shown in image 2 it works but it will ignore the condition of “LP” Parameters which is manual input from the Modeler. and If I directly use the Boolean mask its not updating the newly modeled Duct in only considers.

Thanks and Best Regards…

L.Magno

Hi @Louis_Magno

Could you drop here dummy rvt file with just ducts on it. If your unable to drop here then drop the dummy rvt file in google drive or dropbox and share the link to the rvt file here.

Thanks Kulkul,

I have edited the Scrypt but it I really need to fix the issues like if the Values for the (LP,MP,HP is blank) I think I need to create if conditions that includes the blank values. I send you the Revit files and the “scrypt” see what mess I’m trying to create.

Best Regards…
L.MagnoDuct Gauge Assign Dynamo Script Test AX`.dyn (50.7 KB)

Here the screen capture