(defun sd (/ s a b oecho)
(setq oecho (getvar "cmdecho"))
(setq s (entsel))
(if s
(progn
(setq a (entget (car s)))
(setq b (cdr (assoc 8 a)))
(setvar "cmdecho" 0)
(command "-layer" "s" b "")
(princ (strcat "\n Current layer = " b)))
(princ " Nothing selected "))
(setvar "cmdecho" oecho)
(princ)
)
Function here works fine but if I make it (defun c:sd........), and user misses the target, the message "Nothing selected" displays only on third line (from the bottom) on Command line window. When user doesn't miss the target, the text "Current layer..." displays on second line. If the user has only 2 text lines visible, the text "Nothing selected" will not display. It's only in 2000+++. It works fine in R14.
How can this be controlled?