Moves a set of elements by a given transformation.
Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 24.0.0.0 (24.0.0.0)
Since: 2012
Syntax
C# |
---|
|
Visual Basic |
---|
|
Visual C++ |
---|
|
Parameters
- document
- Type: Autodesk.Revit.DBDocument
The document that owns the elements.
- elementsToMove
- Type: System.Collections.GenericICollectionElementId
The set of elements to move.
- translation
- Type: Autodesk.Revit.DBXYZ
The translation vector for the elements.
Exceptions
Exception | Condition |
---|---|
Autodesk.Revit.ExceptionsArgumentException | The given element id set is empty. -or- One or more elements in elementsToMove do not exist in the document. |
Autodesk.Revit.ExceptionsArgumentNullException | A non-optional argument was null |
Autodesk.Revit.ExceptionsInvalidOperationException | If we are not able to move all the elements (for example, if one or more elements is pinned). -or- Move operation failed. |