
- (defun c:fw ()
- (cond
- ((setq na (entsel "\n选取图形名称:"))
- (setq na (cdr (assoc 1 (entget (car na)))))
- )
- (T (setq na (getstring "\n输入图形名称:")))
- )
- (princ "\n请选择输出对象: ")
- (setq ss (ssget ":s" '((0 . "~xline")))
- date (rtos (getvar "cdate") 2 6)
- 年 (substr date 3 2) ;1 4
- 月 (substr date 5 2)
- 日 (substr date 7 2)
- tim (substr date 10)
- 时 (substr tim 1 2)
- 分 (substr tim 3 2)
- 秒 (substr tim 5 2)
- datime (strcat "(" 年 "" 月 "" 日 "_" 时 "" 分 "" 秒 ")")
- desk (strcat "E:/00/送线割图纸/" na datime)
- )
- (command "WBLOCK" desk "" '(0 0 0) ss "")
- ;; 把选择
- (command "oops")
- (princ "\n选择的对象已完成输出")
- (vlax-invoke
- (vlax-create-object "wscript.shell")
- 'run
- "E:\\00\\送线割图纸"
- )
- (princ)
- )
|