Warnings by Level - Excel/List Structure Issue

I have produced an excel document based on this guide. http://www.martinportfolio.com/blog/2016/8/4/warnings-by-level

I have managed to produce an excel file that organizes the warnings by level. Somehow though the list structure of the data fed into excel is off. See image below.

I am a little over my head with this, but I’m struggling through. I can tell the issue is some simple list structure manipulation, but I can’t seem to reorganize it appropriately.

Any help is much appreciated. Thanks!

1 Like

Hi @ncalvert ,

you only need to add “Level” , “Warning” and “Element” once, at the beginning of your data list :

Okay I’ve made some progress. I think one step I was missing is reorganizing the data before adding “Level”, “Warning”, and “Element” header titles. So now what I’m trying to do is restructure the data in the image below so that each sublist of warning data is grouped by level. The level names start alphabetically at “C00”. After that I can add in the header titles appropriately.

I believe the final list structure would look similar to:

List
___0 List
______0 List
_________0 Level
_________1 Warning
_________2 Element
______1 List
_________0 C00 - SUB-BASEMENT FLOOR
_________1 (1st Warning description here)
_________2 (1st Element description here)
______2 List
_________0 C00 - SUB-BASEMENT FLOOR
_________1 (2nd Warning description here)
_________2 (2nd Element description here)
___1 List
______0 List
_________0 Level
_________1 Warning
_________2 Element
______1 List
_________0 C0 - BASEMENT FLOOR
_________1 (1st Warning description here)
_________2 (1st Element description here)
______2 List
_________0 C0 - BASEMENT FLOOR
_________1 (2nd Warning description here)
_________2 (2nd Element description here)

I see what you mean, but now what I’m struggling with is I need to add “Level”, “Warning”, and “Element” to each sheet. In the image in my first post you can see I have Excel sheets for each level in the project. So I need to get all of the warnings for each level to show up correctly in their respective excel sheets. I think the list structure will look like my second post. Is that correct?

Here’s a suggestion :

You might have to slip a “string from object” node somewhere since your initial list seems to contain revit element.

1 Like

It’s been a while. I’ve been meaning to post my solution. I did eventually get everything figured out, and I now have a functioning script that can produce a correctly updated excel document.

Fighting through this script helped me gain a lot of knowledge of how Dynamo works. Understanding list.map and functions to manage lists was huge for me.

My next goal is experimenting with Dynamo scripts on how to automate the process of addressing some of these errors. Hopefully I’ll be back here soon to post more scripts of those solutions!

I’ve attached the Dynamo script, an image of my workspace, the source excel file, and the resultant excel file.

Again if anyone is looking at this post please refer also to the original link I provided on making this script. It has valuable information.

It is important to note that there was some minor editing in the warnings export from Revit. My process was, export the warnings list from Revit, open the html file in excel, select all and uncheck merge and center, change the sheet name to “Sheet1”, save and close the file, open a blank excel file and save it and close it, select the files in dynamo with the appropriate nodes, then run the Dynamo script while the associated Revit file was open.

Warnings By Level-Working Version.dyn (47.7 KB)

1 Like

Hi ncalvert, Can you tell me where I can find the custom nodes ? BB data etc…?

Cheers

That node is in bumble bee.