Doe this do it?
(defun purge-mleaderstyles (/ mls)
(if (setq mls (vl-remove-if-not
'(lambda (x) (= (car x) 350))
(dictsearch (namedobjdict) "acad_mleaderstyle")
)
)
(mapcar 'entdel (mapcar 'cdr mls))
)
(princ)
)
(purge-mleaderstyles)
The problem is, it will still purge if the style is used or active. Which will cause AutoCAD to crash.
Here's a CRAPPY one I did a while back, just as a proof of concept.
;;; Purge Multileader Styles (since vla-purgeall ignores them)
;;; Alan J. Thompson, 08.24.09
(defun AT:MleaderStylePurge (/)
(vl-remove-if
'null
(mapcar
'(lambda (x)
(and
(eq 350 (car x))
(not (eq 330 (car (nth 5 (entget (cdr x))))))
(not (eq (getvar "cmleaderstyle")
(vla-get-name (vlax-ename->vla-object (cdr x)))
) ;_ eq
) ;_ not
(entdel (cdr x))
) ;_ and
) ;_ lambda
(dictsearch (namedobjdict) "ACAD_MLEADERSTYLE")
) ;_ mapcar
) ;_ vl-remove-if
) ;_ defun
Know that I do not use this, I just have it in a folder of useless subroutines I wrote as learning exercises.