[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] | Reference for unit 'Dialogs' (#lcl)

# TCustomTaskDialog.SetRadioButtonFromRadioIndex

Makes the radio button with the specified identifier the active RadioButton on the task dialog.

## Declaration

Source position: dialogs.pp line 809

`protected procedure TCustomTaskDialog.SetRadioButtonFromRadioIndex(`
`AIndex: Integer`
`);`

## Description

SetRadioButtonFromRadioIndex is a method used to make the radio button specified in AIndex the active (or default) RadioButton on the task dialog.

AIndex is an Integer value which contains the button identifier for the radio button (not its ordinal position) selected from the RadioButtons on the dialog. The TTaskDialogButtons instance with the specified identifier is stored in the RadioButton property. RadioButton may be set to Nil if AIndex is not in the valid range for radio buttons starting at TaskDialogFirstRadioButtonIndex, or RadioButtons does not contain the identifier.

SetRadioButtonFromRadioIndex is called from methods like DoExecute and DoOnRadioButtonClicked.

## Version info

Added in LCL version 4.0.

## See also

TCustomTaskDialog.RadioButton |  | The radio button selected on the Task dialog.
TCustomTaskDialog.RadioButtons |  | Collection with the optional radio buttons defined for the Task dialog.
TCustomTaskDialog.DoExecute |  | Performs actions to configure and execute the dialog.
TCustomTaskDialog.DoOnRadioButtonClicked |  | Sets the active radio button and signals the OnRadioButtonClicked event handler (when assigned).
TTaskDialogButtons |  | Collection type used to access and maintain buttons defined for a Task dialog.
TTaskDialogBaseButtonItem |  | Defines the base class for a custom button displayed on a Task dialog.
TaskDialogFirstRadioButtonIndex |  | Lowest index value for a radio button used on a TTaskDialog instance.