Прошу прощения но моя программа не работает. Дайте пинка чтобы разобраться окончательно
(defun format ( / dcl_id)
(if (< (setq dcl_id (load_dialog "Format_all.DCL")) 0)(exit))
(if (not (new_dialog "Format_dcl" dcl_id)) (exit))
(start_dialog)
(action_tile "A3v" "(setq aaa \"A3v\")")
(action_tile "A4v" "(setq aaa \"A4v\")")
(action_tile "A3g" "(setq aaa \"A3g\")")
(action_tile "A4g" "(setq aaa \"A4g\")")
(done_dialog)
(unload_dialog dcl_id)
(draw_RAMKA aaa)
;;; (princ)
);defun format
(defun draw_RAMKA ( priznak / )
(cond
((= priznak "A3v") (DEFUN draw_A3v (/)
(setq swidth 0.6)
(setq old_ortho (getvar "ORTHOMODE")
old_snap (getvar "SNAPMODE")
old_osnap (getvar "OSMODE"))
(setvar "orthomode" 0)
(setvar "snapmode" 0)
(setvar "osmode" 0)
(command "_.layer" "_m" "_Format" "")
(command "_rectang" "0,0" "297,420" "")
(command "_rectang" "5,5" "292,400" "")
(command "_-vports" "5,5" "292,400" "")
(setvar "ORTHOMODE" old_ortho)
(setvar "SNAPMODE" old_snap)
(setvar "OSMODE" old_osnap)
))
((= priznak "A4v") (DEFUN draw_A4v (/)
(setq swidth 1)
(setq old_ortho (getvar "ORTHOMODE")
old_snap (getvar "SNAPMODE")
old_osnap (getvar "OSMODE"))
(setvar "orthomode" 0)
(setvar "snapmode" 0)
(setvar "osmode" 0)
(command "_.layer" "_m" "_Format" "")
(command "_rectang" "0,0" "210,297" "")
(command "_rectang" "20,5" "205,292" "")
(command "_-vports" "20,5" "205,292" "")
(setvar "ORTHOMODE" old_ortho)
(setvar "SNAPMODE" old_snap)
(setvar "OSMODE" old_osnap)
))
((= priznak "A3g") (DEFUN draw_A3g (/)
(setq swidth 0.6)
(setq old_ortho (getvar "ORTHOMODE")
old_snap (getvar "SNAPMODE")
old_osnap (getvar "OSMODE"))
(setvar "orthomode" 0)
(setvar "snapmode" 0)
(setvar "osmode" 0)
(command "_.layer" "_m" "_Format" "")
(command "_rectang" "0,0" "420,297" "")
(command "_rectang" "20,5" "415,292" "")
(command "_-vports" "20,5" "415,292" "")
(setvar "ORTHOMODE" old_ortho)
(setvar "SNAPMODE" old_snap)
(setvar "OSMODE" old_osnap)
))
((= priznak "A4g") (DEFUN draw_A4g ()
(setq swidth 0.6)
(setq old_ortho (getvar "ORTHOMODE")
old_snap (getvar "SNAPMODE")
old_osnap (getvar "OSMODE"))
(setvar "orthomode" 0)
(setvar "snapmode" 0)
(setvar "osmode" 0)
(command "_.layer" "_m" "_Format" "")
(command "_rectang" "0,0" "297,210" "")
(command "_rectang" "20,5" "292,205" "")
(command "_-vports" "20,5" "292,205" "")
(setvar "ORTHOMODE" old_ortho)
(setvar "SNAPMODE" old_snap)
(setvar "OSMODE" old_osnap)
))
) ; cond
) ; defun draw_RAMKA