Previous post in series [AecLineworkTrim].
I decided not to wait six years between posts on the AEC Modify tools this time. Today's featured command is the AecLineworkDivide command. This command can be accessed on the Home ribbon tab, on the Modify panel flyout or from the right-click context menu (no command active), by choosing AEC Modify Tools > Divide.
The Screencast embedded below shows the AecLineworkDivide command in action. As shown in the Screencast, the command works on linework, Mass Element Extrusions that have an embedded profile, AEC Polygons, Spaces and Block References that contain at least one of the previously mentioned objects.
You can specify the dividing line in two ways (just as you could do so for the AecLineworkExtend and AecLineworkTrim commands), either by selecting two points, as was done in the Screencast, or, by pressing the ENTER key when prompted for the first point, and then hovering over an existing line in the file and left clicking when the desired dividing line is highlighted. No matter which method you choose, the dividing line is treated as being infinite in length; the endpoints need not be outside the extents of the selection set.
When a closed item is divided by the AecLineworkDivide command, the resulting objects are also closed, whether the objects are main objects or nested within a Block Reference. A divided circle results in two closed Polylines. A closed Polyline results in (at least) two closed Polylines. An open Polyline results in at least two polylines, and possibly many more, if the dividing line crosses the Polyline multiple times, as it does in the example in the Screencast.
Here are some additional things of which to be aware when using the AecLineworkDivide command:
- MText, Text, Ellipses and Ellipse Arcs are not dividable and cannot be added to the selection set for the AecLineworkDivide command.
- Mass Elements with a shape other than "Extrusion" and Mass Element Extrusions that have an external Profile assigned are not dividable. If you include these types of Mass Elements in the selection set of the AecLineworkDivide command, the entire object will be duplicated, even if the dividing line does not intersect the Mass Element.
- If you divide a Block Reference with dividable nested objects that has just one instance in the file, then the original block definition will be redefined as the objects on one side, and an anonymous block will be created for the objects on the other side. If there are other instances of a Block Reference that are not in the selection set, then the original definition will be left as is, and anonymous block definitions will be created for both sides of the divided Block Reference.
- When undividable items are present in a block reference that is being divided, the undividable elements will be included in the block definition of both of the newly created blocks.
- Weird things happen when you divide an attributed block. If there are no dividable objects, the attributed block may be "replaced" with an anonymous block, which may not be annotative even if the original block was. If there are dividable items in the attributed block, then you will likely get two blocks, with the attributes in both, although in my tests the actual instance in the file of one of the blocks did not have the attributes, but inserting another instance of it did result in attributes.
- Multi-View Blocks are selectable, but will not actually divide, even if the underlying view block contains dividable graphics. The Multi-View Block will duplicate, however (in place), even if it is not cut by the dividing line. This is actually quite handy in the case of a Multi-View Block Space tag, where you are dividing the Space as well. If you include both the Space and the Tag in the same AecLineworkDivide command selection set, then each of the two Spaces created by the divide will be tagged by one of the two Tags generated. You will still have to manually separate the two Tags.
- In some cases where the object to be divided is irregularly shaped, the divide may create more than two potential objects, for example, a U-shaped closed Polyline or Space divided across the arms of the "U". For the Polyline, you will get three closed Polylines. For the Space, you will only get two Spaces, one of which will have two non-contiguous sub-areas.
- Walls, Doors, Windows and Door/Window Assemblies do not work well with the AecLineworkDivide command. These items will not be split (not even Walls), but they will duplicate in place, creating, in the case of Walls, cleanup nightmares, and duplicate objects in the other cases. I would not recommend including these items in the selection set of the AecLineworkDivide command.
- Associative Spaces are also not good candidates for the AecLineworkDivide command. The entire Space will be duplicated, and both will be associative to the same boundaries. I cannot think of a scenario where that would be the desired end result. Non-associative Spaces work just fine, as seen in the Screencast.
I am sure I have missed some object types or some combination of objects nested inside a Block Reference that have unexpected results when the AecLineworkDivide command is applied. I suggest using the Mark option of the UNDO command to set one or more UNDO Marks prior to using the AecLineworkDivide command in unfamiliar situations, so that you can easily UNDO Back to the Mark if things are not to your liking. That said, there are cases where this command can be handy, when used appropriately.