ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Help / WLanguage / WLanguage functions / Controls, pages and windows / Radio Button functions
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Adds a new option into a Radio Button control. The option is added after the existing options.
Example
// Add 2 options
RADIO_Options.Add("Read a book on a tablet")
RADIO_Options.Add("Read a pocket book")
Syntax
<Result> = <Radio Button control>.Add(<Caption> [, <Sub-caption> [, <Image>]])
<Result>: Integer
  • Index of the new option.
  • -1 if an error occurred. To get more details on the error, use ErrorInfo.
<Radio Button control>: Control name
Name of the Radio Button control into which the option will be added. The option is added after the existing options.
<Caption>: Character string
Text of the option to be added.
<Sub-caption>: Optional character string
Subtext of the option to be added.
If this parameter is not specified, the new option has no subtext.
If this parameter is specified, the sub-caption will be displayed even if the radio button is using a display mode without sub-caption.
<Image>: Optional character string
Image associated with the option to add.
If this parameter is not specified, the added option has no image.
If this parameter is specified, the image will be displayed only if the radio button uses a "Vista style" display mode (with image).
Remarks
  • The characteristics of the added option can also be modified via the following properties used on the option:
  • When adding options into a Radio Button control, the control size is not modified. The added options may not be visible if the control is not large enough. The control can be enlarged by the Width and Height properties.
  • To add an option at a specific position, use <Radio button>.Insert.
  • Using returned values: If the radio button is using the returned values, you have the ability to define the value returned by the added option via ReturnedValue.
    For example:
    nIndex is int
    nIndex = RADIO_Option.Add("Read a book on a tablet")
    RADIO_Option[nIndex].ReturnedValue = "Tablet"
    // Select the new option
    RADIO_Option = "Tablet"
Component: wd290obj.dll
Minimum version required
  • Version 23
This page is also available for…
Comments
IMPORTANTE
PARA ZERAR A LISTA DE OPÇÕES, DEIXANDO TODAS OPTIONS DESMARCADAS, BASTA ATRIBUIR O VALOR -1

TO RESET OPTIONS LIST BY LEAVING ALL OPTIONS UNCLEAR, JUST ASSIGN VALUE -1

POUR RÉINITIALISER LA LISTE DES OPTIONS EN LAISSANT TOUTES LES OPTIONS, JUSTE ASSIGNER LA VALEUR -1

PARA RESTABLECER LA LISTA DE OPCIONES DEJANDO TODAS LAS OPCIONES NO CLARAS, SOLO ASIGNE EL VALOR -1
BOLLER
14 Oct. 2019

Last update: 06/20/2023

Send a report | Local help