Can't get list to sort properly in SetParameterByName


I have an Excel file with HVAC information about hospital rooms. I want to import the supply airflow into Revit. I think I’m almost there, but when I hit ‘run’ it assigns the airflow values to the wrong rooms.

I’m rather new to Dynamo, so please let me know if I’ve made any glaring rookie mistakes :slight_smile:

Couldn’t figure out what are you sorting before, but I think you just need to put another node GetParameterValueByName after the FilterByBoolMask node and use that one to sort the bottom list so you have it properly sorted after filtering and not before.

Also if you have the same number of values as the number of spaces, you don’t need the values on the set parameter node @L2

Rather than sorting and hoping that both lists contain exactly the same names, it’s better to use a filter by matching values. This ensures that you only write to the elements that have matching data.