;;; ;;; ;;; ;;; ;;;Stamps the drawing and logs the saveas. ;;; ;;;Prior to DEFUN below (COMMAND ".undefine" "saveas") is required or this DEFUN will not ;;;redefuine QSAVE (COMMAND ".undefine" "saveas") can be executed from here or anywhere ;;;else as long as it is called before this DEFUN ;;; ;;;> Author: Henry C. Francis ;;;> 425 N. Ashe St. ;;;> Southern Pines, NC 28387 ;;;> http://paracadd.com ;;;> All rights reserved. ;;; ;;;> COPYRIGHT: 12-20-94 ;;;> EDITED: 06-16-2005 ;;; (IF (EQ (SUBSTR (GETVAR "acadver") 1 2) "14") (SETQ DEFUN-Q DEFUN) nil ) ;_ end of IF (DEFUN-Q c:saveas (/ fstr fndexst) (IF initandsdichk NIL (LOAD "initandsdichk" "\nFile INITANDSDICHK.LSP not loaded! ")) (initandsdichk) (SETQ dwgpx (GETVAR "dwgprefix")) (SETQ dwgnm (GETVAR "dwgname")) (SETQ cur_vp (GETVAR "cvport")) (IF (AND (EQ (GETVAR "tilemode") 0) (/= cur_vp 1)) (COMMAND "_.pspace") ) ;_ end of if (SETQ cur_dwgspec (STRCAT (GETVAR "dwgprefix") (GETVAR "dwgname")) cur_file (DOS_FILE cur_dwgspec) ) ;_ end of setq (COMMAND ".saveas" "" "~") (SETQ post_dwgspec (STRCAT (GETVAR "dwgprefix") (GETVAR "dwgname")) post_file (DOS_FILE post_dwgspec) ) ;_ end of setq (IF (EQUAL cur_file post_file) (PRINC "\nNothing Changed!") (PROGN (IF (EQ (GETVAR "dbmod") 0) (PROGN (PRINC (STRCAT " Saved as " (STRCASE (GETVAR "dwgprefix")) (STRCASE (GETVAR "dwgname")) ".\n" ) ;_ end of strcat ) ;_ end of princ ) ;_ end of PROGN (PROGN (PRINC (STRCAT " NOT SAVED as" (STRCASE (GETVAR "dwgprefix")) (STRCASE (GETVAR "dwgname")) "!\n" ) ;_ end of strcat ) ;_ end of princ (ALERT (STRCAT "NOT SAVED as" (STRCASE (GETVAR "dwgprefix")) (STRCASE (GETVAR "dwgname")) "!" ) ;_ end of STRCAT ) ;_ end of ALERT ) ;_ end of PROGN ) ;_ end of if (IF c:backup NIL (LOAD "backup" "\nFile BACKUP.LSP not loaded! ")) (c:backup) (IF (EQ (STRCASE (STRCAT dwgpx dwgnm)) (STRCASE (STRCAT (GETVAR "dwgprefix") (GETVAR "dwgname"))) ) ;_ end of eq (PROGN (SETQ fstr (STRCAT " Saved.................: ")) ) ;_ end of progn (PROGN (SETQ fstr (STRCAT " Saved As " (GETVAR "dwgprefix") (GETVAR "dwgname") ": " ) ;_ end of strcat ) ;_ end of setq ) ;_ end of progn ) ;_ end of if (IF (OR (EQ (GETVAR "tilemode") 1) (AND (>= (STRLEN (GETVAR "dwgname")) 8) (EQ (STRCASE (SUBSTR (GETVAR "dwgname") 6 1)) "X") ) ;_ end of and ) ;_ end of or nil (IF (EQUAL (GETVAR "limmax") (LIST 14.0 8.5) 3) (c:cstmp) (c:lbl) ) ;_ end of IF ) ;_ end of if (IF dlog NIL (LOAD "dlog" "\nFile DLOG.LSP not loaded! ")) (dlog) ) ;_ end of progn ) ;_ end of IF (PRINC) ) ;_ end of defun (PRINC)