public class WebForm1: System.Web.UI.Page{
protected System.Web.UI.WebControls.RadioButton RadioButton1;
protected System.Web.UI.WebControls.RadioButton RadioButton2;
protected System.Web.UI.WebControls.RadioButton RadioButton3;
protected System.Web.UI.WebControls.Image Image1;
protected HtmlForm Form1;
private void Button1_Click(object sender, System.EventArgs e)
{
(1)
{
if(control is RadioButton)
{
RadioButton rb=control as RadioButton;
if(rb.Checked)
{
ListBox1.Items.Add(rb.Text);
break;
}
}
}
}
}
foreach(object control in this.Controls)
foreach(object control in Page.Controls)
foreach(object control in Form1.Controls)
foreach(object control in WebForm1.Controls)