# Contents of a list into multiline codeblock

**URL:** <https://forum.dynamobim.com/t/contents-of-a-list-into-multiline-codeblock/1244>\
**Category:** Packages\
**Created:** [March 26, 2015, 5:57am UTC](https://forum.dynamobim.com/t/contents-of-a-list-into-multiline-codeblock/1244 "2015-03-26T05:57:05Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Shahrokh\_Kamyab](https://avatars.discourse-cdn.com/v4/letter/s/e56c9b/32.png) [@Shahrokh\_Kamyab](https://forum.dynamobim.com/u/Shahrokh_Kamyab)\
**Post date:** [March 26, 2015, 5:57am UTC](https://forum.dynamobim.com/t/contents-of-a-list-into-multiline-codeblock/1244/1 "2015-03-26T05:57:05Z")

</div>

![Image 11](https://cdck-file-uploads-us1.s3.dualstack.us-west-2.amazonaws.com/flex022/uploads/dynamobim/original/2X/9/910a94c73762bb9f6ccc8edd8ab0ffec620a43bf.png)

&nbsp;

&nbsp;

&nbsp;

&nbsp;

&nbsp;

&nbsp;

&nbsp;

&nbsp;

Hello everyone!

Is it possible to convert the contents of a list into multiline codeblock or similar? Because I need separate output fields for every single element of that list.

Regards

//Shahrokh

---

<div class="post-metadata">

**Author:** ![solamour](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/solamour/32/153516_2.png) [@solamour](https://forum.dynamobim.com/u/solamour)\
**Post date:** [March 26, 2015, 9:50am UTC](https://forum.dynamobim.com/t/contents-of-a-list-into-multiline-codeblock/1244/2 "2015-03-26T09:50:40Z")

</div>

![Sublist_Example](https://cdck-file-uploads-us1.s3.dualstack.us-west-2.amazonaws.com/flex022/uploads/dynamobim/original/2X/6/6d43be6366734145518d2bf1bce7f79c4b960253.jpg)

To do it manually you can type (In the Code Block):

Var[0][0]

This will give you the item of list ‘0’ at indice ‘0’ and so on. i.e. If you had more sub lists you would go: Var[0][1][2] and so on an so forth (Where each number corresponds to an indice).

I don’t know how to make this ‘smart’ per see and get what your after sadly. But it’s a start, no?!

---

<div class="post-metadata">

**Author:** ![Shahrokh\_Kamyab](https://avatars.discourse-cdn.com/v4/letter/s/e56c9b/32.png) [@Shahrokh\_Kamyab](https://forum.dynamobim.com/u/Shahrokh_Kamyab)\
**Post date:** [March 26, 2015, 11:05am UTC](https://forum.dynamobim.com/t/contents-of-a-list-into-multiline-codeblock/1244/3 "2015-03-26T11:05:53Z")

</div>

Hello Sol!

It’s definitely a start. Thanks

I’m trying to make Var[a][b] to work though. Say if the indices are parameters.

Look at the images below. Even the Var[a][1] works, but not Var[a][b] !!

Any thoughts on that ?

Regards

&nbsp;

![Image 13](https://cdck-file-uploads-us1.s3.dualstack.us-west-2.amazonaws.com/flex022/uploads/dynamobim/original/2X/9/9762ca82945e514ff64527872e91a933c4957bbd.png)

&nbsp;

&nbsp;

&nbsp;

&nbsp;

&nbsp;

&nbsp;

![Image 14](https://cdck-file-uploads-us1.s3.dualstack.us-west-2.amazonaws.com/flex022/uploads/dynamobim/original/2X/0/01c16e7ddbc18ae0bcc04813ec5ce78c5f0a8c7b.png)

&nbsp;

---

<div class="post-metadata">

**Author:** ![john\_pierson](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/john_pierson/32/191977_2.png) [@john\_pierson](https://forum.dynamobim.com/u/john_pierson)\
**Post date:** [March 26, 2015, 1:51pm UTC](https://forum.dynamobim.com/t/contents-of-a-list-into-multiline-codeblock/1244/4 "2015-03-26T13:51:12Z")

</div>

I was trying to do this same thing the other day. It seems to ignore when you have an input for the indices.
