MODIFICATION IN CODE (TO AVOID CASE SENSITIVE IN TEXT SELECTION FROM LISP)
MODIFICATION IN CODE (TO ACCEPT CASE SENSITIVE IN TEXT SELECTION FROM LISP)
(defun C:SWT ( / str ss sss i txt ) ; = Find String(s) by Content
(setq str (getstring "\nYour [full or partial] string content to search for: "))
(setq sss (ssadd))
(if (setq ss (ssget (list (cons 0 "*TEXT") (cons 410 (getvar 'ctab)))))
(repeat (setq i (sslength ss))
(setq txt (ssname ss (setq i (1- i))))
(if (wcmatch (cdr (assoc 1 (entget txt))) (strcat "*" str "*"))
(ssadd txt sss)
); if
); repeat
); if
(if sss
(sssetfirst nil sss); select/highlight/grip
); if
(princ); quiet exit
); defun
HTH., M.R.