I can't find where I got this from, AND it doesn't work across layouts for some reason, but just a start:
(defun C:Remove_Fields ( / del-field ss1 index item)
(vl-load-com)
(defun del-field (ent / edic elist etype obj val)
(if
(and
(setq edic (cdr (assoc 360 (setq elist (entget ent)))))
(dictsearch edic "ACAD_FIELD")
)
(progn
(setq obj (vlax-ename->vla-object ent)
etype (cdr (assoc 0 elist))
)
(cond
((= etype "DIMENSION")
(setq val (vla-get-textoverride obj))
(dictremove edic "ACAD_FIELD")
(vla-put-textoverride obj val)
)
((= etype "MTEXT")
(setq val (vla-get-textstring obj))
(dictremove edic "ACAD_FIELD")
(vla-put-textstring obj val)
)
(T (dictremove edic "ACAD_FIELD"))
)
)
)
)
(if
(setq ss1
(ssget "X"
(list
(cons 0 "TEXT,MTEXT,MULTILEADER,DIMENSION")
(cons 67 1)
)
)
)
(progn
(setq index 0)
(repeat (sslength ss1)
(setq item (ssname ss1 index))
(if (del-field item) (entupd item))
(setq index (+ 1 index))
)
)
)
(if
(setq ss1
(ssget "X"
(list (cons 0 "INSERT")
(cons 67 1)
(cons 66 1)
)
)
)
(progn
(setq index 0)
(repeat (sslength ss1)
(setq item (ssname ss1 index))
(while (= (cdr (assoc 0 (entget (setq item (entnext item))))) "ATTRIB")
(if (del-field item) (entupd item))
)
(setq index (+ 1 index))
)
)
)
(princ)
)