;function to remove all embedded vba projects from a drawing ;by Jeff Mishler ;massoc as found on adesk newsgroup (defun c:rem_vba_proj (/ mac-attach ) (setq mac-attach (dictsearch (namedobjdict) "ACAD_VBA")) (if mac-attach (progn (getstring "\nFound embedded macro. Enter to delete, ESC to cancel...") (foreach name (massoc 350 mac-attach) (entdel name) ) (dictremove (namedobjdict) "ACAD_VBA") (command "qsave") ) ) ) (defun massoc (key alist / x nlist) (foreach x alist (if (eq key (car x)) (setq nlist (cons (cdr x) nlist)) ) ;end if ) ;end foreach (reverse nlist) ) ;end defun