Query line length

This seems to be so difficult for something I thought would be an easy starting point. Generally just trying to get to know Dynamo.

I have pulled in a group of lines from a current drawing, added them to a flattened list, and extracted one line. Trying to get the line length, or somehow identify the midpoint of the line so I can try to place a piece of text on the midpoint of the line. Seems to be that the only way to do this is to start writing code again…

image

Thanks for the quick reply, couple questions,

Curves are the same as lines?
I don’t see the element.curves node in my list. Does the Dynamo for Civil 3D have less features?

  • Lines same as curves.
  • The shot is taken from dynamo in Revit, I did not deal with the one in C3D.

Well good to know curves=lines. I’ll have to dig around to see what the differences are with the Dynamo for Civil 3D

Curves aren’t equal to lines. They are a special type of curve. Computationally speaking a Curve is any type of non-branching 2 dimensional object, including lines, polygons, arcs, circles, ellipses, NURBS curves, and polycurves.

More info can be found here: Geometry Overview | The Dynamo Primer

2 Likes