Revit 2026 API
Element |
Moves one element by a given transformation.
Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 26.0.4.0 (26.0.4.0)
Syntax
public static void MoveElement( Document document, ElementId elementToMove, XYZ translation )
Public Shared Sub MoveElement ( document As Document, elementToMove As ElementId, translation As XYZ )
public: static void MoveElement( Document^ document, ElementId^ elementToMove, XYZ^ translation )
static member MoveElement : document : Document * elementToMove : ElementId * translation : XYZ -> unit
Parameters
| Exception | Condition |
|---|---|
| ArgumentException | The element elementToMove does not exist in the document |
| ArgumentNullException | A non-optional argument was null |
| InvalidOperationException | If we are not able to move the element (for example, if it is pinned). -or- Move operation failed. |
See Also