Writing excel values into element parameters, where the elements are positioned based on coordinates from same excel sheet

Hi Guys,

I have managed to position and color sphere target elements into the revit model space based on an excel survey stakeout report. The spheres are modelled and colored based on whether the stakeout positions are within tolerance. In the excel sheet the columns list the point ID, easting, northing, elevation, yes or no whether it is in tolerance or not in position and height. It also specifies the exact dimensions / residuals relating to these points.

I am trying to write back in these residuals into the modelled element parameters. I have been successful in doing so, however, they do not match up (i.e. The wrong residuals are being written into the wrong elements).

Have you guys got any idea what would be the best way to match up the residuals to the newly created list of sphere element GUID’s within the model space?
Plate Check iCON Demo.xlsx (19.1 KB)
Hopefully the images attached will make what I am trying to achieve that little bit clearer.

Added note: The points positions in the excel sheet are in a national grid but the spheres modelled locations have been translated and rotated relative to the project base point.

Write the values in line as the spheres are created in lieu of getting all Elements of Family Type. If that doesn’t work, you will need to use a Filter by Bool Mask with an “==” node to check the Point Name parameter again the value per row assuming there aren’t any duplicates.

Hi Sean, I get what you are saying. I have attached the rvt file, dyn script and excel file. If you could run it and give me an example of how you think it could be done I would really appreciate it. Just finding it hard to picture how I would write it.


Stakeout List Import V5.7 - Final Rev2.dyn (273.4 KB) Plate Check iCON Demo.xlsx (19.1 KB)

I think you have 1 too many 'Drops" and it takes the Name out of the list. The image is a bit crude, but if you set the name for all of the points created as they are created then you can “get” them later. Another way would be to use the “point” data from the create instance and write that into the sphere right after creating it.

For me the divergent data stream where you split the “In Tolerance 2d” and “In Tolerance Height” into separate lists is what is causing the issues. So, what then we need to do is get the value in those lists as and index, filter the name list by the same bool, then find the item at the index and use that to set the parameter in the new instance.

Keep in mind that you will need to do this for each tolerance nodes IN and OUT values.

Sean that worked perfectly. Really appreciate that!

1 Like