Hi @Yellowjacket98,
This is a bit delayed, but I thought I’d offer my thoughts in case you’re still working on this. There were quite a few things that I identified that would make this script a lot cleaner, so instead of talking through all of them, I’m just posting a new version. Give it a try and post any questions you have.
Note that I’m also posting a new Excel file with an additional sheet at the end. It looks like this may be some type of standard company spreadsheet, in which case it may take some work to change, but…I highly recommend that you simplify the data that is being read by Dynamo so that you have a single row of column headers followed by the data entries. In the long run, this is going to be more bulletproof and much easier to work with in Dynamo as opposed to a large group of nodes with the sole purpose of shifting indices, removing nulls, removing/adding indices, etc. As it stands, even a simple change to the spreadsheet (eg. adding a row or swapping the order of columns) would break the whole script.
pipes_MZJ.xlsx (659.5 KB)
Pipes - by network2_MZJ.dyn (57.3 KB)