Skip to main content

Radio Buttons

Overview

Radio Button allows users to select a single option within a group of options.

When users select a Radio Button, other Radio Buttons in the same group can not be selected.

  • Radio Button

RadioButton1

Properties

PropertyDescription
CheckedWhether the current control is checked.
Click EventWhether to trigger a click event to the current control.
Hint TextShow hint text when the mouse is hovering over the control.

Events

addCallBack1

Callback NameCallback Function
on_clickThe callback after left-clicking.
on_right_clickThe callback after right-clicking.
on_checked_changedThe callback when the control changes its check state.

Lua Script Example

self.Checked = true
self.ClickEvent = true
self.HintText = nx_widestr("RadioButton")

-- When left-clicking the RadioButton, the on_click function will be executed.
function RadioButton_click(self)
nx_msgbox("RadioButton_click")
end