Summary

This article contains an ArcObjects code sample that demonstrates how to split a polyline at the vertices, creating separate lines from each line segment.

Procedure

  1. Start ArcMap.
  2. Create a new UIButtonControl.
  3. Right-click the UIButtonControl and select View Source.
  4. Copy and paste the following code into the UIButtonControl's click event.

  5. The code above calls a routine called "AddFields". To support this, copy and paste this code so it follows the "End Sub" of the Click event handler above.

    End Sub

  6. In ArcMap, select the polyline layer whose features you want to split. Click the newly created button to split all the lines in this layer.

相关文章: