# Need Help With Python Scripting

**URL:** <https://forum.dynamobim.com/t/need-help-with-python-scripting/13278>\
**Category:** Revit\
**Tags:** revit, python, dynamo\
**Created:** [July 18, 2017, 6:29pm UTC](https://forum.dynamobim.com/t/need-help-with-python-scripting/13278 "2017-07-18T18:29:23Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![bradwitt](https://avatars.discourse-cdn.com/v4/letter/b/9de0a6/32.png) [@bradwitt](https://forum.dynamobim.com/u/bradwitt)\
**Post date:** [July 18, 2017, 6:29pm UTC](https://forum.dynamobim.com/t/need-help-with-python-scripting/13278/1 "2017-07-18T18:29:23Z")

</div>

Hello All -  
I am very very new to Python, such as I am going through the course at codecademy. I found this blog by @maarten vroegindeweij, and thought it was trying to do the same thing I am trying to do with a floor slab. It works! However, the dimensions are not for just one side of a slab, they are also dimensioning any changes on the opposite side.

 ![](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/1/d/1de563b0df6988c57b20257f5cd73fcd18663339.png)

I am trying to set it up so I can dimension each side of the slab that I choose, and tried using the Select Faces as well as Select Edges node but no luck.  
I was wondering if anyone out there had any suggestions on how I could either tweak the graph, or the python code.

 ![](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/0/7/079e661ee60164886e12efe39b478ce0e1a94e81.png)

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

Thank you any help is appreciated. I have been trying to work out an auto dimension for slab edges for months now.

Brad

---

<div class="post-metadata">

**Author:** ![4bimfercesp](https://avatars.discourse-cdn.com/v4/letter/4/b782af/32.png) [@4bimfercesp](https://forum.dynamobim.com/u/4bimfercesp)\
**Post date:** [July 18, 2017, 6:47pm UTC](https://forum.dynamobim.com/t/need-help-with-python-scripting/13278/2 "2017-07-18T18:47:29Z")

</div>

Hi…welcome to python. I just want to asked if you do select a line? On a specific side?

---

<div class="post-metadata">

**Author:** ![bradwitt](https://avatars.discourse-cdn.com/v4/letter/b/9de0a6/32.png) [@bradwitt](https://forum.dynamobim.com/u/bradwitt)\
**Post date:** [July 18, 2017, 6:52pm UTC](https://forum.dynamobim.com/t/need-help-with-python-scripting/13278/3 "2017-07-18T18:52:38Z")

</div>

yes, I have placed four detail lines, one on each side and then select the one on the side I am trying to dimension

---

<div class="post-metadata">

**Author:** ![4bimfercesp](https://avatars.discourse-cdn.com/v4/letter/4/b782af/32.png) [@4bimfercesp](https://forum.dynamobim.com/u/4bimfercesp)\
**Post date:** [July 18, 2017, 6:56pm UTC](https://forum.dynamobim.com/t/need-help-with-python-scripting/13278/4 "2017-07-18T18:56:47Z")

</div>

You have 11 edges? Correct on one side? Where you select the detail line reference?

---

<div class="post-metadata">

**Author:** ![bradwitt](https://avatars.discourse-cdn.com/v4/letter/b/9de0a6/32.png) [@bradwitt](https://forum.dynamobim.com/u/bradwitt)\
**Post date:** [July 18, 2017, 6:58pm UTC](https://forum.dynamobim.com/t/need-help-with-python-scripting/13278/5 "2017-07-18T18:58:12Z")

</div>

sounds about right

---

<div class="post-metadata">

**Author:** ![4bimfercesp](https://avatars.discourse-cdn.com/v4/letter/4/b782af/32.png) [@4bimfercesp](https://forum.dynamobim.com/u/4bimfercesp)\
**Post date:** [July 18, 2017, 7:00pm UTC](https://forum.dynamobim.com/t/need-help-with-python-scripting/13278/6 "2017-07-18T19:00:57Z")

</div>

Python looks alright i need to check on a pc? For the meantime can you do a simple slab and place the line on one side only and run graph (i think you done this already dont you?)…it appears to me also that the location of the for element in elements maybe in the wrong location coz of this its remembering your previous selection.

---

<div class="post-metadata">

**Author:** ![bradwitt](https://avatars.discourse-cdn.com/v4/letter/b/9de0a6/32.png) [@bradwitt](https://forum.dynamobim.com/u/bradwitt)\
**Post date:** [July 18, 2017, 7:04pm UTC](https://forum.dynamobim.com/t/need-help-with-python-scripting/13278/7 "2017-07-18T19:04:09Z")

</div>

yeah I have already done that. So if the script is fine, I am assuming it has to do with the graph and suing the edges node.

---

<div class="post-metadata">

**Author:** ![4bimfercesp](https://avatars.discourse-cdn.com/v4/letter/4/b782af/32.png) [@4bimfercesp](https://forum.dynamobim.com/u/4bimfercesp)\
**Post date:** [July 18, 2017, 7:13pm UTC](https://forum.dynamobim.com/t/need-help-with-python-scripting/13278/8 "2017-07-18T19:13:06Z")

</div>

If you post your dyn so others can help for the meantime i am not on a pc at the moment and it will be tomorrow before i can help as its night time here in my part of the world. I think if you just create a simple slab with manually selecting an edge (there is a node for this OOTB i just forgot the name) and try your python. Also i can see you have IN[2] do you not get an error?

---

<div class="post-metadata">

**Author:** ![bradwitt](https://avatars.discourse-cdn.com/v4/letter/b/9de0a6/32.png) [@bradwitt](https://forum.dynamobim.com/u/bradwitt)\
**Post date:** [July 18, 2017, 7:15pm UTC](https://forum.dynamobim.com/t/need-help-with-python-scripting/13278/9 "2017-07-18T19:15:14Z")

</div>

I had there in there testing something, but it didn’t work. Here is the dyn file.[Dimensional Floor-online edit.dyn](https://forum.dynamobim.com/uploads/short-url/7AWbxWJVJnFWBUAn60gklOYHPWb.dyn) (19.8 KB)

---

<div class="post-metadata">

**Author:** ![4bimfercesp](https://avatars.discourse-cdn.com/v4/letter/4/b782af/32.png) [@4bimfercesp](https://forum.dynamobim.com/u/4bimfercesp)\
**Post date:** [July 18, 2017, 7:30pm UTC](https://forum.dynamobim.com/t/need-help-with-python-scripting/13278/10 "2017-07-18T19:30:37Z")

</div>

Did you try this post it looks like it has been resolved and the code was posted…

> [@Automatic Dimension Walls](https://forum.dynamobim.com/t/automatic-dimension-walls/6970):
>
> Hi Everyone, I was inspired by the new build-in node for dimensioning elements in Revit. I tried to dimension few walls with this build-in node but it dimensions the walls only from center line to center line. That don’t works for me so I dig a little bit and made a python script that dimensions the walls from face to face. But my goal is to make the python script to dimension both faces of the wall, not only the right one ( in this example). Can anyone help me in the python scripting so th…

Thanks
