(defun c:replace_insert	(/ blknm en fillet ss *error*)
  (setq en (car (fsxm-entsel "\n请选择源图块:" '((0 . "INSERT")))))
  (or en (fsxm-silenceexit))
  (redraw en 3)
  (defun *error* (msg) (redraw en 4) (princ))
  (setq blknm (fsxm-getendxf en 2))
  (setq	fillet (list '(0 . "INSERT")
		     '(-4 . "<NOT")
		     (cons 2 blknm)
		     '(-4 . "NOT>")
	       )
  )
  (vla-StartUndoMark *doc*)
  (princ "\n请择将要被替换的图块：")
  (while (setq ss (ssget ":S" fillet))
    (foreach a (fsxm-ss->enlist ss) (fsxm-setendxf a 2 blknm))
    (princ (strcat "\n●替换了" (itoa (sslength ss)) "个..."))
  )
  (vla-EndUndoMark *doc*)
  (*error* 0)
)