TemporaryCAD Posted July 27, 2022 Posted July 27, 2022 I'm looking to copy the default behavior of the line command, where it continuously prompts user input until escape is pressed. How would I best go about implementing this in Autolisp? Quote
Tharwat Posted July 27, 2022 Posted July 27, 2022 (edited) You can use it with while function with getpoint function. (if (setq p1 (getpoint "\nSpecify a point : ")) (while (setq p2 (getpoint "\nNext point : " p1)) (entmake (list '(0 . "LINE") (cons 10 p1) (cons 11 p2))) (setq p1 p2) ) ) Edited July 27, 2022 by Tharwat codes added 1 1 Quote
mhupp Posted July 27, 2022 Posted July 27, 2022 Another way (command "line" (while (< 0 (getvar 'CMDACTIVE)) (command pause)) ) 2 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.