DgsRadioButtonGetSelected

From Multi Theft Auto: Wiki
Jump to navigation Jump to search

This function gets a radio button's selection state.

Syntax

bool dgsRadioButtonGetSelected( element RadioButton)

Required Arguments

  • RadioButton: The radio button you wish to retrieve the selection state of.

Returns

Returns true if the radio button is selected, false if it is not.


Example

DGS = exports.dgs 
button1 = DGS:dgsCreateRadioButton( 243, 204, 36, 16, "test1", false ) --Create a radio button
button2 = DGS:dgsCreateRadioButton( 243, 234, 36, 16, "test2", false ) --Create another radio button
addEventHandler("onDgsMouseClickUp",root,function()
	if DGS:dgsRadioButtonGetSelected( button1 ) then
		outputChatBox("Radio Button 1 is checked")
	else
		outputChatBox("Radio Button 1 is unchecked")
	end
end)

See Also

Custom Cursor Functions

Multi Language Supports

Animation

3D Interface

3D Line

3D Image

3D Text

Browser

Button

Check Box

Combo Box

Custom Renderer

Edit

Detect Area

Drag'N Drop

Grid List

Image

Memo

Label

Line

Progress Bar

Radio Button

Scale Pane

Scroll Bar

Scroll Pane

Selector

Style

Switch Button

Tab Panel

Window

Plugin

Blur Box

Color Picker

Canvas

Circle

Effect 3D

Media Browser

Mask

Nine Slice

Object Preview Supports

Paste Handler

QRCode

Remote Image

Rounded Rectangle