@AnonymousI have spent yesterday almost four hours creating this code. In essence this should be easy task to do but it has produced a lots of troubles in execution. To create angular dimension there are two options, one using command dimangular (used in code) or with entmake (complicated).
With command approach there are several options to create direction angle depending on pick order pf polyline segments . Sometime result can be smaller angle (direction) and sometime you can receive larger angle ie angle between two poly segments. I have included a little trick that should force only creation of direction angle, and if it works it works correctly. For some angles between segments order of selection would probably have to be reversed, and different math should be used. Of course this code only works with line segments.
I would run code on whole length, without dividing. Before using adang command you should remove all zero length segments (command overkill) or explode end remove all lines with length less then 0.5, or equal to 0, and join back to polyline. Run the code and create angular dims where they are created wrong.
Miljenko Hatlak
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.