Skip to content

menu Radio

menu Radio {name} {x} {y} {width} {height} {checked} {text...}

Also searchable as: menu Radio · option button

menu Radio creates a radio button. Of the radio buttons with the same parent (a window or a menu Panel), only one is checked at a time.

Parameter Meaning
name The button’s name.
x, y Position inside the current default parent.
width, height Size in pixels.
checked #true to check it, #false not to. Checking it unchecks the others in the same parent.
text The label; the rest of the line.
menu Window Size 120 100
menu Radio easy 10 10 80 20 #true Easy
menu Radio hard 10 35 80 20 #false Hard
menu Button go 10 65 60 25 Go
menu Show
set #MenuButton N/A
while #MenuButton = N/A
wait 1
menu Get hard
if #MenuRes = -1
display ok Hard it is.
else
display ok Easy it is.
halt

See also

The EasyUO 1.6 behaviour on this page was researched with help from the ScriptUO community: Gaderian's tutorial New Menu Code and how to adapt old scripts and the scripts its members share at scriptuo.com.