Export to Excel, then Import values calculated in Excel back to part libraries

I’ve been working on a pretty large script that reads a “Line Number” off pipe objects that have been selected.

First the User enters a “Line Number” to their selection set using stock Revit tools;

Run the script, select components in Revit you want to process;

Read line number from object along with the Element ID and Object type, Dynamo writes these to an Excel table, then performs a VLOOKUP on another sheet where line data will be entered. The data that matches the “Line Number” then gets pushed back to all of the Revit objects in the selection set, to help populate our NDE requirements to the fabrication shop.

Currently, the place where I’m struggling is writing the line items back from EXCEL to Revit Objects (Along with how to walk thru an index with Dynamo, but that’s another subject.)


What I don’t understand is why it can’t find the parameters available to write on the parts. I assume my input Element.Set.Parameterbyname list isn’t matching, but I can’t figure that part out. My Revit Project has everything I’m writing as a parameter already on the parts, and a project parameter set for the link.


Also my 8 “Get Item at Index” to process the list seems rough, is there better methods for itemizing a list for processing the data?

Attached will be the script and the EXCEL file.







Hopefully the attachments worked this time.

Got some huge updates solved on this, since no one has replied I figured I’d leave an update. It works now, but there’s still a lot of work to do. Currently, it pulls a parameter “Line Number” off the Revit components. Dumps them into a table in Excel Excel performs a VLOOKUP to populate the line number spool data for a few parameters (So far) Populated Excel fields are pushed back and written to the selected Revit objects!

There’s a bunch of extra data in the script still as it’s a WIP.