never mind, got it. I should make the user press enter twice

Registered forum members do not see this ad.
I need a lisp to use DT command in a way that when the user press the enter no new line get started and command ends, how should I do it? absolutely no idea

never mind, got it. I should make the user press enter twice


Registered forum members do not see this ad.
In case you may still be interested, here is a program to do what you asked for.
The rotation angle is the default (zero) and the current text size is used. You could, of course, add code to get these values from the user.Code:(defun Text (pt hgt str) (entmakex (list (cons 0 "TEXT") (cons 10 pt) (cons 11 pt) (cons 40 hgt) (cons 72 0) ; lower left justified (cons 1 str))) ) (defun c:dtxx (/ *ERROR* osave c txtstr txtsz) (defun *ERROR* (msg) (setvar "OSMODE" osave) (princ) ) (setq osave (getvar "OSMODE")) (setvar "OSMODE" 0) (setq txtsz (getvar "TEXTSIZE")) (setq c (getpoint "\nSelect location: ")) (initget 129) (setq txtstr (getstring T "\nText: ")) (terpri) (terpri) (Text c txtsz txtstr) (setvar "OSMODE" osave) (princ) )
Bookmarks