Small Bug in my Radio Box Script<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />My Radio Box script is:
Panel Box("Pick a record type", rbox = Radio Box( {"CLA", "CLD", "CNT", "FN2", "FRA", "MDB", "MDC","MIS", "UTI", "VLR" },
rb = rbox << Get Selected ),
Problem: If the user deosn't make a selection, that is, leaves the Radio Box at the default "CLA" , the variable rb is blank. If the user selects any other record type from the list, the correct value is assigned to rb.
Thanks!
Rob in Reston
Re: Small Bug in my Radio Box ScriptYour welcome.
Re: Small Bug in my Radio Box ScriptThanks bthaby, it worked liked a charm.
Re: Small Bug in my Radio Box ScriptTry setting it on the first pass. . rb = rbox << set(1);
See example below.
getrb = expr(
rb = rbox << Get Selected;
show(rb);
);
rb = "";
show(rb);
NewWindow("test",
PanelBox("Pick a record type", rbox = RadioBox({"CLA", "CLD", "CNT", "FN2", "FRA", "MDB", "MDC", "MIS", "UTI", "VLR"},getrb),
rb = rbox << set(1);
rb = rbox << Get Selected;
show(rb);
);
);