@Kent1Cooper wrote:
@tramber wrote:
....
angle12(angle(cdr(assoc 10(entget ent)))(cdr(assoc 11(entget ent)))))
....
That will work to put them on the ends of Lines, but not Polylines as in the Subject line. If this is the solution, then the Subject line is mis-worded. Whether or not the OP really needs it only for Lines, I wouldn't want others looking for one to do it on Polylines to think that this is going to work.
If you want something that will work on Polylines, as well as Lines, Arcs, open-ended Splines or Ellipses, even closed Polylines/Splines/Ellipses & Circles [though in such cases it will put one marker at the location that is both "ends" of a closed object], you can use the DIV+ command in DivideMeasurePlus.lsp, available here. It has an option to mark the division points with Lines [one of two options beyond just Points or Blocks as in regular DIVIDE], for which you specify the length. When it asks how many segments to divide into, say 1 [regular DIVIDE doesn't allow that], and when it asks whether to put them at the ends [regular DIVIDE doesn't have that option], say Yes. Accept the defaults for everything else except if you want to specify a Layer other than the default current one. Then go around and pick things of any of those types, and it will mark their ends with Lines, centered on and perpendicular to the end points. It remembers all your choices and offers them as defaults on subsequent use.
Kent Cooper, AIA