INTRODUCTION:-
A radio button, sometimes called an option button, is circular control that comes in a group with other controls of the same type. Each radio button is made of a small empty circle O. From the group, when the user clicks one of them, the radio button that was clicked becomes filled with a big dot 8. When one of the radio buttons in the group is selected and displays its dot, the others display empty circles. To guide the user as to what the radio buttons mean, each is accompanied by a label.
To create a radio button, on the Toolbox, you can click the RadioButton control . Alternatively, you can declare a RadioButton class and use the form's constructor to initialize the radio buttons. Because radio buttons always come as a group, you should include them in another control that visibly shows that the radio buttons belong to the same group. The most common control used for this purpose is the group box created using the GroupBox control
To create a radio button, on the Toolbox, you can click the RadioButton control . Alternatively, you can declare a RadioButton class and use the form's constructor to initialize the radio buttons. Because radio buttons always come as a group, you should include them in another control that visibly shows that the radio buttons belong to the same group. The most common control used for this purpose is the group box created using the GroupBox control
CODE OF RADIO BUTTON:-
If (radiobutton1.Checked==true)
{
MessageBox.Show("OK");
}
else
{
MessageBox.Show("Error");
}
No comments:
Post a Comment