The RadioButton is used to select one option from the number of choices. If we want to select only one item from a related or group of items in the windows forms, we can use the radio button. The RadioButton is mutually exclusive that represents only one item is active and the remains unchecked in the form.
Let's create a RadioButton control in the VB.NET Windows by using the following steps.
Step 1: Drag the RadioButton control from the toolbox and drop it to the Windows form, as shown below.
Step 2: Once the RadioButton is added to the form, we can set various properties of the RadioButton by clicking on the Radio control.
There are following properties of the VB.NET RadioButton control.
||It is used to set or get a value representing whether the RadioButton allows the user to drag on the form.
||It is used to get or set a value that represents the appearance of the RadioButton.
||It is used to get or set the radio control in ScrollControlIntoView(Control).
||The AutoCheck property is used to check whether the checked value or appearance of control can be automatically changed when the user clicked on the RadioButton control.
||The AutoSize property is used to check whether the radio control can be automatically resized by setting a value in the RadioButton control.
||A CanSelect property is used to validate whether a radio control can be selected by setting a value in the RadioButton control.
||It is used to obtain or set a value that indicates the location of the check portion in the radioButton control.
||The Text property is used to set the name of the RadioButton control.
||The Contains() method is used to check if the defined control is available in the RadioButton control.
||It is used to send the specified message to the Window procedure.
||It is used to destroy the handle associated with the RadioButton Control.
||The Focus() method is used to set the input focus to the window form's RadioButton control.
||It is used to return a value that represents how the control will operate when the AutoSize property is enabled in the RadioButton control of the Window form.
||As the name suggests, a ResetText() method is used to reset the property of text to its default value or empty.
||It is used to reroute an invalid field, which causes control in the client region.
We can also refer to Microsoft documentation to get a complete list of RadioButton Control properties and methods in the VB .NET.
Let's create a program to understand the uses of Radio button control in the VB.NET form.
Click on the Submit button. It shows the following message on the screen.