# How to create a beam system using Python

**URL:** <https://forum.dynamobim.com/t/how-to-create-a-beam-system-using-python/17016>\
**Category:** Revit\
**Created:** [December 1, 2017, 11:10am UTC](https://forum.dynamobim.com/t/how-to-create-a-beam-system-using-python/17016 "2017-12-01T11:10:08Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![Myhail\_Veselkin](https://avatars.discourse-cdn.com/v4/letter/m/b782af/32.png) [@Myhail\_Veselkin](https://forum.dynamobim.com/u/Myhail_Veselkin)\
**Post date:** [December 1, 2017, 11:10am UTC](https://forum.dynamobim.com/t/how-to-create-a-beam-system-using-python/17016/1 "2017-12-01T11:10:08Z")

</div>

Good afternoon friends! I address to professionals. I tried to look for the possibility of creating a beam system in revit by means of a dynamo, but, alas, I could not find a suitable node, the only option was to create a beam system with the help of a python. In Revit Api, I found four methods, but the knowledge for the correct syntax of all the necessary input data, unfortunately, is not enough. I understand that I ask, perhaps, a lot, because if anyone has the opportunity and desire to share thoughts, a big thanks!!

 ![Безымянный](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/e/5/e5415b07fb3358e06196531d9141840073b3348c.jpg) ![Capture1](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/7/a/7a9fa67f5e324eb45c61a8d005c95c93e538cd34.png)  
Dynamo File [https://drive.google.com/open?id=1ynaEvYXzQjQG1PDLh2ab4Qg-j27zgUkL](https://drive.google.com/open?id=1ynaEvYXzQjQG1PDLh2ab4Qg-j27zgUkL)

---

<div class="post-metadata">

**Author:** ![Yna\_Db](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/yna_db/32/30641_2.png) [@Yna\_Db](https://forum.dynamobim.com/u/Yna_Db)\
**Post date:** [December 1, 2017, 11:53am UTC](https://forum.dynamobim.com/t/how-to-create-a-beam-system-using-python/17016/2 "2017-12-01T11:53:36Z")

</div>

It would probably be useful to list first which elements are needed:

> **[Create an Automatic Beam System | Revit Products 2016 | Autodesk Knowledge...](https://knowledge.autodesk.com/support/revit-products/learn-explore/caas/CloudHelp/cloudhelp/2016/ENU/Revit-Model/files/GUID-53449E14-6E16-4641-9023-332CC40DD59A-htm.html)**
>
> Create beam systems quickly, with one mouse click. You can place beam systems with one click if the following conditions are met: The one-click beam system can only be added in plan or ceiling view with a horizontal sketch plane. If the view or the...

  
[http://www.revitapidocs.com/2017.1/e84d68b9-b128-c2fd-a8e9-d9afdf3a613a.htm](http://www.revitapidocs.com/2017.1/e84d68b9-b128-c2fd-a8e9-d9afdf3a613a.htm)

---

<div class="post-metadata">

**Author:** ![Myhail\_Veselkin](https://avatars.discourse-cdn.com/v4/letter/m/b782af/32.png) [@Myhail\_Veselkin](https://forum.dynamobim.com/u/Myhail_Veselkin)\
**Post date:** [December 1, 2017, 12:10pm UTC](https://forum.dynamobim.com/t/how-to-create-a-beam-system-using-python/17016/3 "2017-12-01T12:10:50Z")

</div>

Thanks for the reply, Yna\_Db! I do not have the necessary experience, so I’m interested in the most understandable way for me to create a beam system using the method [http://www.revitapidocs.com/2017.1/633b2057-876e-80d6-bac3-42a036dad2a4.htm](http://www.revitapidocs.com/2017.1/633b2057-876e-80d6-bac3-42a036dad2a4.htm). I scan the api, maybe it will work out, thanks!

---

<div class="post-metadata">

**Author:** ![Yna\_Db](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/yna_db/32/30641_2.png) [@Yna\_Db](https://forum.dynamobim.com/u/Yna_Db)\
**Post date:** [December 1, 2017, 12:16pm UTC](https://forum.dynamobim.com/t/how-to-create-a-beam-system-using-python/17016/4 "2017-12-01T12:16:07Z")

</div>

> [@Myhail\_Veselkin](#):
>
> I do not have the necessary experience

Neither do I with this kind of elements, but since we can learn something from this discussion, an accurate information will be welcome 🙂

---

<div class="post-metadata">

**Author:** ![MJB-online](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/mjb-online/32/24884_2.png) [@MJB-online](https://forum.dynamobim.com/u/MJB-online)\
**Post date:** [December 1, 2017, 12:26pm UTC](https://forum.dynamobim.com/t/how-to-create-a-beam-system-using-python/17016/5 "2017-12-01T12:26:34Z")

</div>

Hi @Myhail_Veselkin,

The DynamoPrimer contains a chapter on Python, and it also explains how to create an array of beams.  
[http://dynamoprimer.com/en/09\_Custom-Nodes/9-5\_Python-Revit.html](http://dynamoprimer.com/en/09_Custom-Nodes/9-5_Python-Revit.html)  
Maybe it can point you in the right direction.

Kind regards,  
Mark

---

<div class="post-metadata">

**Author:** ![Myhail\_Veselkin](https://avatars.discourse-cdn.com/v4/letter/m/b782af/32.png) [@Myhail\_Veselkin](https://forum.dynamobim.com/u/Myhail_Veselkin)\
**Post date:** [December 1, 2017, 12:51pm UTC](https://forum.dynamobim.com/t/how-to-create-a-beam-system-using-python/17016/6 "2017-12-01T12:51:33Z")

</div>

Hello Mark! I am very grateful to you for this link, a very interesting script, perhaps I will refuse now the idea of creating a beam system and will be thinking in the direction of creating the beams themselves. Useful information for studying!

---

<div class="post-metadata">

**Author:** ![Myhail\_Veselkin](https://avatars.discourse-cdn.com/v4/letter/m/b782af/32.png) [@Myhail\_Veselkin](https://forum.dynamobim.com/u/Myhail_Veselkin)\
**Post date:** [December 1, 2017, 1:49pm UTC](https://forum.dynamobim.com/t/how-to-create-a-beam-system-using-python/17016/7 "2017-12-01T13:49:24Z")

</div>

I’m working on the option of creating a beam system using the examples of the Revit API, it is not possible to specify the correct method to use the python. By default, for some reason, the first method is selected, the python shows an error File “”, line 42, in TypeError: expected SketchPlane, got Level. Can I somehow indicate that I need a third method?  
 ![Безымянный2](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/b/6/b633f352dddff7ede1d482c48b351e58b8057a4d.jpg) ![Безымянный1](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/5/7/5705146433ca38282565d0bd0b44a0f5071c01b8.jpg)

---

<div class="post-metadata">

**Author:** ![Yna\_Db](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/yna_db/32/30641_2.png) [@Yna\_Db](https://forum.dynamobim.com/u/Yna_Db)\
**Post date:** [December 1, 2017, 2:01pm UTC](https://forum.dynamobim.com/t/how-to-create-a-beam-system-using-python/17016/8 "2017-12-01T14:01:19Z")

</div>

See if this helps maybe:

 ![image](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/3/b/3b2058aab089dcf9090f6cf4b20d23e5bb2c5c1e.png)

---

<div class="post-metadata">

**Author:** ![Myhail\_Veselkin](https://avatars.discourse-cdn.com/v4/letter/m/b782af/32.png) [@Myhail\_Veselkin](https://forum.dynamobim.com/u/Myhail_Veselkin)\
**Post date:** [December 1, 2017, 2:31pm UTC](https://forum.dynamobim.com/t/how-to-create-a-beam-system-using-python/17016/9 "2017-12-01T14:31:15Z")

</div>

Thanks, Yna\_Db, tried to create the first method. using the nodes you suggested, but now the python produces a strange error: File “”, line 43, in TypeError: expected SketchPlane, got SketchPlane

---

<div class="post-metadata">

**Author:** ![Myhail\_Veselkin](https://avatars.discourse-cdn.com/v4/letter/m/b782af/32.png) [@Myhail\_Veselkin](https://forum.dynamobim.com/u/Myhail_Veselkin)\
**Post date:** [January 3, 2018, 4:38pm UTC](https://forum.dynamobim.com/t/how-to-create-a-beam-system-using-python/17016/10 "2018-01-03T16:38:31Z")

</div>

Good evening! Tell me please what am I doing wrong? It’s about creating a beam system. Thank you for attention. The script gives an error

 ![1111111](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/6/9/69a6ef5d5b6b91072e91f1e12b72314030aba5fa.jpg) Warning: IronPythonEvaluator.EvaluateIronPythonScript operation failed.  
Traceback (most recent call last):  
File “”, line 44, in   
Exception: A managed exception was thrown by Revit or by one of its external applications.
