本帖最后由 作者 于 2009-10-8 23:16:11 编辑
circle.dcl程序 rect:dialog { label="画圆程序" ; :edit_box //编辑框元件 { label="输入圆心 : " ; key="rect_w" ; edit_limit=16; edit_width=20; fixed_width=true; } :edit_box //编辑框元件 { label="输入半径 :" ; key="rect_h" ; edit_limit=16; edit_width=20; fixed_width=true; } ok_cancel; }
circle.lsp程序 (defun c:rect() (setq dcl_id (load_dialog "circle")) (new_dialog "rect" dcl_id) (action_tile "accept" "(sae_alue)") (start_dialog) (unload_dialog dcl_id) ) (defun c:yuan() (setq pt (getpoint "输入圆心坐标:")) (setq r (getreal "输入半径")) (command "circle" pt r ) ) (defun sae_alue () (setq r (atof (get_tile "rect_h")) (setq pt (atof (get_tile "rect_w")) (done_dialog) ) 求高手帮忙看看这个程序哪里有问题,为什么DCL控制无法实现
|