Hello,
Below is an example of a script file from this site. I am going to use this example
to batch plot drawings. Can somebody please edit this so that I can make several
copies of the plots. Let say I need to plot 3 copies of each file I selected. I'd
like it to run it 3 times. Run 1 set first..then the second..then the third.
;batch_anything.lsp
;Created XXXXXXXX
;Date: Sept of 2002
;Description: Batch Process
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;start prog
(DEFUN C:batch_anything ()
;;;;;;;;;;;;;;;;;;;;;;;;;Select directory to be processed
(setq dfil (getfiled "Select A File In The Directory You Want To Batch Process" "p:/" "dwg" 0))
(setq wutdir (vl-filename-directory dfil))
(setq wutfiles (vl-directory-files wutdir "*.dwg"))
(setq scrfile (open "c:\\scrfile.scr" "w"))
(close scrfile)
(setq scrfile (open "c:\\scrfile.scr" "a"))
(foreach n wutfiles
(setq n2 (strcat "\""wutdir "\\" n "\""))
(setq n2 (vl-string-translate "\\" "\\" n2))
(setq scrline (strcat "open" " " n2 " " "(load\"YOURLISP\")" " " "YOURLISP" " " "qsave" " " "close"));;;;;;;COMMANDS FOR BATCH GO HERE
(write-line scrline scrfile)
(princ)
)
(close scrfile)
(command "script" "c:\\scrfile")
(princ "\n***Batch complete.***")
(princ)
);;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;DEFUN