# Issue with extracting nested lists to excel

**URL:** <https://forum.dynamobim.com/t/issue-with-extracting-nested-lists-to-excel/60086>\
**Category:** Uncategorized\
**Created:** [February 4, 2021, 12:23am UTC](https://forum.dynamobim.com/t/issue-with-extracting-nested-lists-to-excel/60086 "2021-02-04T00:23:03Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![ischmitt](https://avatars.discourse-cdn.com/v4/letter/i/a9a28c/32.png) [@ischmitt](https://forum.dynamobim.com/u/ischmitt)\
**Post date:** [February 4, 2021, 12:23am UTC](https://forum.dynamobim.com/t/issue-with-extracting-nested-lists-to-excel/60086/1 "2021-02-04T00:23:04Z")

</div>

I have an issue exporting the nested list. Right now after using List Transpose, I’ve arrived in the position where it’s categorized by rooms as main list levels containing elements such as Element Name Width and height as a nested element. I can not figure out how to transfer it to Excel where the first column would be the room name followed by the sub elements

---

<div class="post-metadata">

**Author:** ![AmolShah](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/amolshah/32/103244_2.png) [@AmolShah](https://forum.dynamobim.com/u/AmolShah)\
**Post date:** [February 4, 2021, 12:38am UTC](https://forum.dynamobim.com/t/issue-with-extracting-nested-lists-to-excel/60086/2 "2021-02-04T00:38:43Z")

</div>

@ischmitt Can you please share a screenshot of your graph?

---

<div class="post-metadata">

**Author:** ![ischmitt](https://avatars.discourse-cdn.com/v4/letter/i/a9a28c/32.png) [@ischmitt](https://forum.dynamobim.com/u/ischmitt)\
**Post date:** [February 4, 2021, 2:38pm UTC](https://forum.dynamobim.com/t/issue-with-extracting-nested-lists-to-excel/60086/3 "2021-02-04T14:38:14Z")

</div>

I’ve tried but it does not allow me to upload anything due to me being a new user sorry about that.  
Basically lists is nested the following way:  
_0 List_  
_0 List_  
0 Room#1  
_1 List_ (Contains name of the element that is located in the room)  
_2 List_ (Contains width of the element that is located in the room)  
_3 List_ (Contains height of the element that is located in the room)  
_1 List_  
0 Room#2  
_1 List_ (Contains name of the element that is located in the room)  
_2 List_ (Contains width of the element that is located in the room)  
_3 List_ (Contains height of the element that is located in the room)

I’ve tried everything, but I can not make it extract to excel when it would follow the formatting  
1st column - Room Name  
2nd column - Element Name  
3rd column - Element Width  
4th column - Element Height

---

<div class="post-metadata">

**Author:** ![Nick\_Boyts](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/nick_boyts/32/76313_2.png) [@Nick\_Boyts](https://forum.dynamobim.com/u/Nick_Boyts)\
**Post date:** [February 4, 2021, 2:42pm UTC](https://forum.dynamobim.com/t/issue-with-extracting-nested-lists-to-excel/60086/4 "2021-02-04T14:42:08Z")

</div>

It looks like your list structure has too many sets of sublists. Excel only accepts data in a 3D list (one list with one set of sublists.)

---

<div class="post-metadata">

**Author:** ![AmolShah](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/amolshah/32/103244_2.png) [@AmolShah](https://forum.dynamobim.com/u/AmolShah)\
**Post date:** [February 4, 2021, 4:01pm UTC](https://forum.dynamobim.com/t/issue-with-extracting-nested-lists-to-excel/60086/5 "2021-02-04T16:01:14Z")

</div>

@ischmitt Works fine for me. Can’t help much unless you share the graph.

 ![image](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/b/3/b366bdf148b5db51cee8c2280524345f5612297d.png)  
You can upload the screenshot on Google Drive, Dropbox, WeTransfer, etc and share a link here.

---

<div class="post-metadata">

**Author:** ![ischmitt](https://avatars.discourse-cdn.com/v4/letter/i/a9a28c/32.png) [@ischmitt](https://forum.dynamobim.com/u/ischmitt)\
**Post date:** [February 4, 2021, 4:11pm UTC](https://forum.dynamobim.com/t/issue-with-extracting-nested-lists-to-excel/60086/6 "2021-02-04T16:11:19Z")

</div>

It works fine with one item per list, but I have Room as the main list with other elements being sub-lists of the room. thanks for the google drive idea I’ve attached a link with the Revit file and dynamo script as well.  
[BIM - Google Drive](https://drive.google.com/drive/folders/1S_LjT6mgeTzad6UOo6_MuSCrrMbwc987?usp=sharing)[Files](https://drive.google.com/drive/folders/1S_LjT6mgeTzad6UOo6_MuSCrrMbwc987?usp=sharing)

---

<div class="post-metadata">

**Author:** ![AmolShah](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/amolshah/32/103244_2.png) [@AmolShah](https://forum.dynamobim.com/u/AmolShah)\
**Post date:** [February 4, 2021, 5:46pm UTC](https://forum.dynamobim.com/t/issue-with-extracting-nested-lists-to-excel/60086/7 "2021-02-04T17:46:56Z")

</div>

@ischmitt This should solve your problem.  
[Elements Extraction by Room.dyn](https://forum.dynamobim.com/uploads/short-url/zGl4xBIft7WGbzTck0yZw5tgerH.dyn) (59.9 KB)

 ![Elements Extraction by Room_2021-02-04_09-46-26](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/9/f/9f4d37e8b842270ee8777c3b17a4fc58b08931cd.png)

---

<div class="post-metadata">

**Author:** ![ischmitt](https://avatars.discourse-cdn.com/v4/letter/i/a9a28c/32.png) [@ischmitt](https://forum.dynamobim.com/u/ischmitt)\
**Post date:** [February 4, 2021, 7:54pm UTC](https://forum.dynamobim.com/t/issue-with-extracting-nested-lists-to-excel/60086/8 "2021-02-04T19:54:42Z")

</div>

Yep that did the trick! Thank you for your help!!
