;;;Lists just names of all XREFs attached, one per line. ;;; ;;;> Author: Henry C. Francis ;;;> 425 N. Ashe St. ;;;> Southern Pines, NC 28387 ;;;> http://paracadd.com ;;;> All rights reserved. ;;; ;;;> COPYRIGHT: ;;;> EDITED: 01-28-2005 ;;; (defun c:xrfs (/ blk_def blk_lst xrlst_in xrlst_out line_in ex_xr_lst) (setq blk_def (tblnext "block" T)) (if (assoc 1 blk_def) (setq blk_lst (list (cdr (assoc 1 blk_def)))) ) ;_ end of if (while (setq blk_def (tblnext "block")) (if (assoc 1 blk_def) (setq blk_lst (append (list (cdr (assoc 1 blk_def))) blk_lst)) ) ;_ end of if ) ;_ end of while (if (eq (dos_drivetype (substr (getvar "dwgprefix") 1 2)) "CDROM") (setq xrlst_file (findfile (strcat "C:" "XREF_USE.LST"))) (setq xrlst_file (findfile (strcat (getvar "dwgprefix") "XREF_USE.LST"))) ) (if xrlst_file (progn (setq xrlst_in (open xrlst_file "r")) (while (setq line_in (read-line xrlst_in)) (if (not ex_xr_lst) (setq ex_xr_lst (list line_in)) (setq ex_xr_lst (append (list line_in) ex_xr_lst)) ) ;_ end of if ) ;_ end of while (close xrlst_in) ) ;_ end of progn ) ;_ end of if (progn (foreach n blk_lst (if (member n ex_xr_lst) nil (setq ex_xr_lst (append (list n) ex_xr_lst)) ) ;_ end of if ) ;_ end of foreach (if ex_xr_lst (progn (if (eq (dos_drivetype (substr (getvar "dwgprefix") 1 2)) "CDROM") (setq xrlst_outfn (strcat "C:" "XREF_USE.LST")) (setq xrlst_outfn (strcat (getvar "dwgprefix") "XREF_USE.LST")) ) (setq ex_xr_lst (acad_strlsort ex_xr_lst)) (setq xrlst_out (open xrlst_outfn "w")) (foreach n ex_xr_lst (write-line n xrlst_out) ) ;_ end of foreach (close xrlst_out) ) ;_ end of progn ) ;_ end of if ) ;_ end of progn (mapcar '(lambda (x) (princ (strcat "\n" x))) blk_lst ) ;_ end of mapcar (princ) ) ;_ end of defun ;|«Visual LISP© Format Options» (72 2 40 2 T "end of " 60 9 0 0 0 T T nil T) ***Don't add text below the comment!***|;