Message 1 of 9
Not applicable
05-30-2018
11:16 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello everyone,
Choose the No.1 wall:
ElementArray arr = (wall1.Location as LocationCurve).get_ElementsAtJoin(0);
arr values :[wall1,wall2]
__________________________________________
I want to add the No.3 wall to the ElementArray .
elementArray = [wall1,wall2,wall3]
(wall1.Location as LocationCurve).set_ElementsAtJoin(0, elementArray);
The error information is as follows:
Autodesk.Revit.Exceptions.InvalidOperationException
at Autodesk.Revit.DB.LocationCurve.set_ElementsAtJoinInternal(Int32 end, List`1 elements)
at Autodesk.Revit.DB.LocationCurve.set_ElementsAtJoin(Int32 end, ElementArray elements)
at Revit.numWall.Execute(ExternalCommandData commandData, String& message, ElementSet elements)
Solved! Go to Solution.