测试了一下, 发现上传的代码有一点笔误, 改正如下
(defun C:VIEWDCL (/ DCL_FILE DCL_ID DCL_PT DD DIA_NAME PRINC) (if (null dcl_pt) (setq dcl_pt '(-1 -1)) ) (setq dcl_file (getfiled "打开DCL文件" "" "DCL" 2)) (princ "DCL文件名:") (princ dcl_file) (setq dia_name (getstring "\nDialog对话框名:")) (if (= dia_name "") (exit) ) (setq dcl_id (load_dialog dcl_file)) (new_dialog dia_name dcl_id) (action_tile "accept" "(setq dcl_pt (done_dialog 1))") (action_tile "cancel" "(done_dialog 0)") (setq dd (start_dialog)) (cond ((= dd 1) (princ "\n确定<OK>!!!")) ((= dd 0)) (princ "\n取消<cancel>!!!") ) (prin1))
LISP 编辑本身有DCL的预览功能, 如下图所示
|