Would example like this help?
Names Default To Here(1);
//radiobox variables
enableList = {2,5};
rbItems = {"one", "two", "three", "four", "five"};
rb = Radio Box(rbItems);
//start as all disabled
For(i = 1, i <= N Items(rb << get items), i++,
rb << enable item(i,0);
);
//enable based on enableList
For(i = 1, i <= N Items(enableList), i++,
rb << enable item(enableList[i],1);
);
//change first selection to first in enableList (otherwise will be first in rbItems)
rb << Set(enableList[1], 1);
//create modal
ok_pressed = 0;
ex = New Window("Dialog() example",
<<Modal,
V List Box(
rb,
H List Box(
Button Box("OK", ok_pressed = 1; rbSelection = rb << get),
Button Box("Cancel", ok_pressed = 0)
)
)
);
If(ok_pressed == 1,
show(rbSelection);
show(rbItems[rbSelection]);
);
-Jarmo