# Feed instead of meter(or centimeters), why?

**URL:** <https://forum.dynamobim.com/t/feed-instead-of-meter-or-centimeters-why/54598>\
**Category:** Developers\
**Created:** [August 30, 2020, 8:56pm UTC](https://forum.dynamobim.com/t/feed-instead-of-meter-or-centimeters-why/54598 "2020-08-30T20:56:15Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![Draxl\_Andreas](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/draxl_andreas/32/145744_2.png) [@Draxl\_Andreas](https://forum.dynamobim.com/u/Draxl_Andreas)\
**Post date:** [August 30, 2020, 8:56pm UTC](https://forum.dynamobim.com/t/feed-instead-of-meter-or-centimeters-why/54598/1 "2020-08-30T20:56:15Z")

</div>

Hello Dynos,

I have a small question, so my code worked very well, but i get “imperial” values inspite of “metric” ones, why?

```
OUT = UnwrapElement(IN[0]).get_Parameter(BuiltInParameter.ROOM_PERIMETER).AsDouble()

```

How can i use the Units from the open document?

KR

Andreas

 ![2020-08-30_22h44_16](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/5/9/595e78aa72ac7b362b3dc2c2751e300521d7f903.png)

---

<div class="post-metadata">

**Author:** ![habdirad](https://avatars.discourse-cdn.com/v4/letter/h/ecd19e/32.png) [@habdirad](https://forum.dynamobim.com/u/habdirad)\
**Post date:** [August 30, 2020, 9:07pm UTC](https://forum.dynamobim.com/t/feed-instead-of-meter-or-centimeters-why/54598/2 "2020-08-30T21:07:02Z")

</div>

Revit API internal unit is decimal feet, you have to convert it either manually (there are dynamo nodes that convert values between units) or using DisplayUnitType api:  
[https://www.revitapidocs.com/2020/9cc2c0ea-f59f-9d76-ce19-ae7eede03bbd.htm](https://www.revitapidocs.com/2020/9cc2c0ea-f59f-9d76-ce19-ae7eede03bbd.htm)

---

<div class="post-metadata">

**Author:** ![jacob.small](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/jacob.small/32/161030_2.png) [@jacob.small](https://forum.dynamobim.com/u/jacob.small)\
**Post date:** [August 31, 2020, 2:33am UTC](https://forum.dynamobim.com/t/feed-instead-of-meter-or-centimeters-why/54598/3 "2020-08-31T02:33:13Z")

</div>

Heads up: I believe that this API changes pretty significantly in 2021.

---

<div class="post-metadata">

**Author:** ![Draxl\_Andreas](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/draxl_andreas/32/145744_2.png) [@Draxl\_Andreas](https://forum.dynamobim.com/u/Draxl_Andreas)\
**Post date:** [August 31, 2020, 8:08am UTC](https://forum.dynamobim.com/t/feed-instead-of-meter-or-centimeters-why/54598/4 "2020-08-31T08:08:51Z")

</div>

Thank you … I use Revit 2018.3

I can`t solve it with any call for the current doc?

---

<div class="post-metadata">

**Author:** ![MartinSpence](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/martinspence/32/25208_2.png) [@MartinSpence](https://forum.dynamobim.com/u/MartinSpence)\
**Post date:** [August 31, 2020, 9:44am UTC](https://forum.dynamobim.com/t/feed-instead-of-meter-or-centimeters-why/54598/5 "2020-08-31T09:44:12Z")

</div>

There’s no way around it. You’ll have to convert one way or the other 🙂

---

<div class="post-metadata">

**Author:** ![Draxl\_Andreas](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/draxl_andreas/32/145744_2.png) [@Draxl\_Andreas](https://forum.dynamobim.com/u/Draxl_Andreas)\
**Post date:** [August 31, 2020, 10:57am UTC](https://forum.dynamobim.com/t/feed-instead-of-meter-or-centimeters-why/54598/6 "2020-08-31T10:57:49Z")

</div>

```
OUT = UnitUtils.ConvertFromInternalUnits(UnwrapElement(IN[0]).get_Parameter(BuiltInParameter.ROOM_PERIMETER).AsDouble(), DisplayUnitType.DUT_METERS)

```

🙂 it worked! i just copy paste something, i want to understand

DUT\_ stays for what?

---

<div class="post-metadata">

**Author:** ![MartinSpence](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/martinspence/32/25208_2.png) [@MartinSpence](https://forum.dynamobim.com/u/MartinSpence)\
**Post date:** [August 31, 2020, 11:10am UTC](https://forum.dynamobim.com/t/feed-instead-of-meter-or-centimeters-why/54598/7 "2020-08-31T11:10:23Z")

</div>

Excellent 🙂

**D** isplay **U** nit **T** ype is my best bet 😉

---

<div class="post-metadata">

**Author:** ![FabioDeAgostini](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/fabiodeagostini/32/93820_2.png) [@FabioDeAgostini](https://forum.dynamobim.com/u/FabioDeAgostini)\
**Post date:** [August 31, 2020, 1:39pm UTC](https://forum.dynamobim.com/t/feed-instead-of-meter-or-centimeters-why/54598/8 "2020-08-31T13:39:08Z")

</div>

Tip: you can dinamically change to the “correct” type using the Parameter [DisplayUnitType property](https://www.revitapidocs.com/2020/3a33606a-fcd4-485b-ed19-b3a879166726.htm)
