When you want a user to select one option in a group, add radio buttons to your form. Only one radio button in a group can be selected at a time. Radio buttons enable the user to provide a value that is returned to the application when a transaction occurs at runtime. Radio buttons, have special characteristics when added to a GridPanel, or form.
When you add a radio button to a form, it has a label attached to it automatically. The label can have its text properties specified for that particular combined object.
Property |
Function |
---|---|
Direction | Read-only. Specifies the value of the Direction property of the attribute associated with the RadioButton object. |
Id | Read-only. By default, automatically generated. Id="RadioButton1" for the first inserted RadioButton, Id="RadioButton2" for the second, and so on. |
Length | Read-only. Specifies the Length of the attribute associated with the RadioButton object. |
Name | Read-only. Specifies the name of the attribute associated with the RadioButton object. |
Primitive | Read-only. Specifies the value of the Primitive property of the attribute associated with the RadioButton object. |
BackgroundColor | Specifies a background color for the object. Select a color from one of the tabs in the drop-down list. Note that you can specify a custom color. If you change this value, you can restore the default value specified for the parent object by right-clicking the property and clicking Reset on the context menu. |
BackgroundImage | Specifies an image to appear in the background of the control. The image always appears as a tiled image. |
Checked | Specifies the initial state of the radio button. When set to True, any other radio button in the same group is set to False. |
ControlType | Specifies RadioButton as the type of object added to the form. To change the ControlType, choose from the list of available types. |
Font | Specifies font attributes that are applied directly to the text appearing in the object. If you change this value, you can restore the default value specified for the parent object by right-clicking the property and clicking Reset on the context menu. |
ForegroundColor | Specifies a foreground color for the object. Select a color from one of the tabs in the drop-down list. Note that you can specify a custom color. If you change this value, you can restore to the default value specified for the parent object by right-clicking the property and clicking Reset on the context menu. |
Location | Specifies the point in pixels that represents the upper-left corner of the object relative to the upper-left corner of its container as an X and Y location. |
Size | Specifies the size of the object representing the height and width in pixels. |
TabIndex | Specifies the index that defines the tab order for the object. |
Text | Specifies the text to be displayed on the object |
TextAlign | Specifies whether the text in the object is left-aligned, right-aligned, center-aligned, or justified. |
TextPosition | Specifies the position of the label relative to the object. The choices are Left and Right (default). |
ToolTip | Specifies an optional tooltip to appear when the user at runtime hovers the mouse over a control in Winforms. To view the tooltip in the Presentation Client, the user has to hover over the control and press the F1 key. This tooltip is visible only at runtime. |
Value | Specifies the value to be displayed on the object. This value is returned to the application when a transaction occurs at runtime. |