To copy all values from a calculated value column determining the occupant load of rooms to a corresponding parameter-based column for use in room tagging.
I have the following script.
The first problem I’m having is the Set Param at the end is failing saying the parameter’s storage type is not a string. I think, but am not sure, that this is due to some of the fields in the column having a null value. I added the ToNumber (the param is set to be an integer) to cast the potentially string value to a number, but that also generates an error. Again, I think this might also be because of the null values in some fields. This does appear to fill in the fields as desired, though. Do I need some way of ignoring the null fields or just let the error happen?
Second problem that doesn’t seem to be breaking the final outcome, is the collection of the calculated field column is also grabbing the final overall total. In this example, I have a total of 38 rooms, but I’m getting 39 values in the calculated field list.
Third problem that isn’t really a problem, yet. I am collecting the rooms and then sorting by room number. The schedule is sorted by level and then by room number and that is the order, I assume, that the calculated value list is always going to be in. It would follow the order of the schedule, right? How would I order the rooms list by level, then by number to make sure the ordering is the same in both lists?
Finally, if anyone can offer any better ways to handle any portion of this, I’m all ears. I’m still very much a novice at Dynamo!!!