CAD_Noob Posted November 24, 2025 Posted November 24, 2025 Does anyone have a lisp that can add multiple vertex for polyline? I found this Lisp from the great @Lee Mac and it works except that I need to be able to pick simultaneously even if it does not reside on the line then hit escape or enter when done. I will then move the added vertex to its proper location. Quote
CAD_Noob Posted November 24, 2025 Author Posted November 24, 2025 Update found this from gile https://forums.augi.com/showthread.php?68868-Adding-vertexes-to-a-polyline&p=765721&viewfull=1#post765721 can it be modified so i can pick multiple points until I exit? Quote
Steven P Posted November 24, 2025 Posted November 24, 2025 So is your question really how to make these loop, keep picking points until you hit enter or escape? Quote
mhupp Posted November 24, 2025 Posted November 24, 2025 (edited) Since Lee's Code only has you picking a point its easy enough. Just add a call at the end of APV (line 95) to call itself again. This will force a loop that you have to hit esc to exit. - Edit This is a better option. Has undo marks. You could also set your snaps before entering the command if you want to. ;;----------------------------------------------------------------------------;; ;; Add Polyline Vertex loop ;; Dependent AddLWPolylineVertexV1-1.lsp (defun C:APVL ( / ) (vl-load-com) (princ "\nStarting Add Polyline Vertex loop. Press ESC to stop.") (vla-StartUndoMark (setq doc (vla-get-ActiveDocument (vlax-get-Acad-Object)))) ;(setvar 'OSMODE 3) ;End and mid point snaps (while T (C:APV) ) (princ "\nAdd Polyline Vertex Loop ended.") (vla-EndUndoMark doc) (princ) ) Edited November 24, 2025 by mhupp 2 Quote
Lee Mac Posted November 24, 2025 Posted November 24, 2025 Or just call MULTIPLE before calling APV. 3 Quote
CAD_Noob Posted November 25, 2025 Author Posted November 25, 2025 12 hours ago, mhupp said: Since Lee's Code only has you picking a point its easy enough. Just add a call at the end of APV (line 95) to call itself again. This will force a loop that you have to hit esc to exit. - Edit This is a better option. Has undo marks. You could also set your snaps before entering the command if you want to. ;;----------------------------------------------------------------------------;; ;; Add Polyline Vertex loop ;; Dependent AddLWPolylineVertexV1-1.lsp (defun C:APVL ( / ) (vl-load-com) (princ "\nStarting Add Polyline Vertex loop. Press ESC to stop.") (vla-StartUndoMark (setq doc (vla-get-ActiveDocument (vlax-get-Acad-Object)))) ;(setvar 'OSMODE 3) ;End and mid point snaps (while T (C:APV) ) (princ "\nAdd Polyline Vertex Loop ended.") (vla-EndUndoMark doc) (princ) ) Hi thanks a lot. It works. 12 hours ago, mhupp said: 8 hours ago, Lee Mac said: Or just call MULTIPLE before calling APV. how can i call multiple prior to calling APV? A friend of mine got me this vlx file but there is an annoying pop-up but it works as well addv.vlx 1 Quote
mhupp Posted November 25, 2025 Posted November 25, 2025 1 hour ago, CAD_Noob said: How can i call multiple prior to calling APV? Glad it works. 1 hour ago, CAD_Noob said: ..how can i call multiple prior to calling APV? Yes. 1 Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.