明经CAD社区

 找回密码
 注册

QQ登录

只需一步,快速开始

搜索
查看: 1601|回复: 1

[LISP]及对话框问题请教大虾

[复制链接]
发表于 2005-4-11 11:57 | 显示全部楼层 |阅读模式
我编写了一个程序,想点击radio_button后赋与popup_list 不同的列表,但列表长度(项数)不一样,但选取长的列表中的值时,只能选取后两项.请教大虾:部份程序如下: (defun c:aaa ()
(setq dcl_id1 (load_dialog "aaa.dcl"))
(if (null (new_dialog "aaa" dcl_id1))
(exit)
)
(ACTION_TILE "alum1" "(gettype)")
(ACTION_TILE "alumplastic" "(gettype)")
(action_tile
"splatethk"
"(sub_disp (nth (atoi $value) splatethk-list))"
)
(start_dialog)
(unload_dialog dcl_id1)
(princ)
) (defun sub_disp (newstr)
(set_tile "splatethk" newstr)
(prin1)
) (defun gettype ()
(setq m1 (GET_TILE "alum1"))
(setq m2 (GET_TILE "alumplastic"))
(COND ((= m1 "1")
(SETQ splatethk-list
(list "2.0"
"2.5"
"3.0"
"4.0"
)
)
)
((= m2 "1")
(SETQ splatethk-list
(list "4.0"
"6.0"
)
)
)
)
(start_list "splatethk")
(mapcar 'add_list splatethk-list)
(end_list)
(set_tile "splatethk" "0")
) aaa: dialog {
label = "金属幕墙计算程序--------cxb编于2005年04月";
:boxed_column{
label="设计地震荷载qE:";
:popup_list {
label = "金属板厚度Tgl(mm):";
key ="splatethk";
value="0";
list="2.0\n2.5\n3.0\n4.0";
fixed_width=true;
}
:boxed_radio_column {
label = "金属板类型:";
:radio_button {
label = "单层铝板";
key = "alum1";
value=1;
}
:radio_button {
label = "铝塑复合板";
key = "alumplastic";

}
}
:button{
label ="刷新数据";
key = "updatemetal";
width=20;
height=4;
fixed_width=true;
}
}
ok_cancel;
}
发表于 2005-4-11 16:56 | 显示全部楼层
不明白你的意思
您需要登录后才可以回帖 登录 | 注册

本版积分规则

小黑屋|手机版|CAD论坛|CAD教程|CAD下载|联系我们|关于明经|明经通道 ( 粤ICP备05003914号 )  
©2000-2023 明经通道 版权所有 本站代码,在未取得本站及作者授权的情况下,不得用于商业用途

GMT+8, 2024-5-3 04:37 , Processed in 0.946291 second(s), 25 queries , Gzip On.

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

快速回复 返回顶部 返回列表