# Circumvent Revit Object "replacement"

**URL:** <https://forum.dynamobim.com/t/circumvent-revit-object-replacement/7459>\
**Category:** Uncategorized\
**Created:** [November 11, 2016, 10:46pm UTC](https://forum.dynamobim.com/t/circumvent-revit-object-replacement/7459 "2016-11-11T22:46:42Z")\
**Posts on this page:** 1\
**Showing post:** 8

<div class="post-metadata">

**Author:** ![Einar\_Raknes](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/einar_raknes/32/8566_2.png) [@Einar\_Raknes](https://forum.dynamobim.com/u/Einar_Raknes)\
**Post date:** [November 13, 2016, 8:23pm UTC](https://forum.dynamobim.com/t/circumvent-revit-object-replacement/7459/8 "2016-11-13T20:23:18Z")

</div>

@Michael_Kirschner Does the .ToDSType(bool) method have anything to do with element binding?

> **[Python 0.6.3 to 0.7.x Migration](https://github.com/DynamoDS/Dynamo/wiki/Python-0.6.3-to-0.7.x-Migration#wrapping)**
>
> Open Source Graphical Programming for Design. Contribute to DynamoDS/Dynamo development by creating an account on GitHub.

> Wrapping

> In order to interoperate with our Revit nodes, any raw Autodesk.Revit.DB.Element being returned from a Python script must be wrapped in a Revit.Elements.Element. This can be done by using the ToDSType(bool) extension method. The bool argument determines whether or not the Element is “Revit-owned.” This distinction is important: Revit-owned Elements are not controlled by Dynamo, non-Revit-owned Elements are. Basically, if you are creating a new Element in your Python script, then you should not mark the wrapped Element as Revit-owned. If you are selecting an Element from the Document, then you should mark the wrapped Element as Revit-owned.

---

_[View the full topic](https://forum.dynamobim.com/t/circumvent-revit-object-replacement/7459)._
