Skip to content

menu SetProp

menu SetProp {name} {property} {value...}

Also searchable as: menu SetProp · property · change property · tooltip

menu SetProp changes one property of a control, or of a window made by menu Form (the main window is form0). The properties are listed on menu GetProp.

Parameter Meaning
name The control or window.
property Which property; not case-sensitive.
value The new value; for text properties, the rest of the line.
  • Text properties (text, tooltip, fontname) take the rest of the line.
  • Numbers must be written as numbers. A colour name such as red counts as 0, which is black: use $0000FF for red.
  • Yes/no properties: #true, or any number other than 0, is yes.
  • parent moves the control into another window or panel by its name, keeping its left and top. A label or an image cannot hold controls; neither can the control itself.
  • width and height of a form set the size of its inside, exactly.
menu Form opts 300 200 200 100 Options
menu Button ok 60 60 80 25 OK
menu SetProp ok tooltip Saves the options and closes the window
menu SetProp ok fontstyle 1
menu SetProp opts color $C0FFC0
menu SetProp opts visible #true
set #MenuButton N/A
while #MenuButton = N/A
wait 1
menu SetProp opts visible #false
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.