@rogersmi87 wrote:
Is there a comman to create points on the corners of a polyline?
For instance, at each corner of a recatangular pond?
....
BeekeeCZ's/alanjt's routine apparently does only one LW[only]Polyline at a time. Here's a [lightly tested but apparently viable] way to do that for as many as you want to select, all at once, and they can be LW, "heavy" 2D or 3D Polylines, or any combination of varieties. It works in different UCS's. It puts the Points on the current Layer, but could be made to match the Layer of the Polyline, and there are other possible enhancements, such as to set a PDMODE value for Point visibility.
(defun C:PPV (/ ppvss n pl m); = Points at all Polyline Vertices
(prompt "\nTo place Points at the vertices of all selected Polylines,")
(if (setq ppvss (ssget '((0 . "*POLYLINE"))))
(repeat (setq n (sslength ppvss)); then
(setq pl (ssname ppvss (setq n (1- n))))
(repeat
(setq m (+ (fix (vlax-curve-getEndParam pl)) (if (vlax-curve-isClosed pl) 0 1)))
(command "_.point" "_none" (trans (vlax-curve-getPointAtParam pl (setq m (1- m))) 0 1))
); repeat [within each Polyline]
); repeat [through selection]
(prompt "\nNo Polyline(s) selected.")
); if
(princ)
); defun
(vl-load-com)
Kent Cooper, AIA