基本上我正在构建一个包含不同显示框的自定义交互式窗口,并且我正在尝试使用 for 循环来简化选择输入。 例如,我有一个组合框和一个 collistbox,我正在尝试使用循环语句获取两者的输入。 但是当我这样做时,我得到了一个错误。 我写的表达式不正确吗? (附错误日志)
Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
New Window( "Col List Box Example",
vlistbox(
var1 = combobox({"one", "two", "three"}),
hlistbox(Col List Box( all, width( 250 ), maxSelected( 1 ) ),
var2 = Col List Box()
)
)
);
var2 << append("height");
AA = {"",""};
for(i=1,i<=2,i++,
temp1 = "var"||char(i);
eval(
substitute(
expr(try(AA[i] = expr.temp1 << get, AA[i] = expr.temp1 << get items)), //try to use get, if error, use get items
expr(expr.temp1),parse(temp1)
)
)
);
show(AA);