title: C# radio button array, how to find selected
body: <p>I have the following c# code that will create a radio button array.
  How could I check which button was selected without going through each button individually?</p>
  
  <p>Thanks.</p>
  
  <pre><code> public Form1()
          {
              InitializeComponent();
              string[] stringArray = new string[3];
  
              stringArray[0] = "Yes";
              stringArray[1] = "No";
              stringArray[2] = "Maybe";
  
              System.Windows.Forms.RadioButton[] radioButtons = new System.Windows.Forms.RadioButton[3];
  
              for (int i = 0; i &lt; 3; ++i)
              {
                  radioButtons[i] = new RadioButton();
                  radioButtons[i].Text = stringArray[i];
                  radioButtons[i].Location = new System.Drawing.Point(10, 10 + i * 20);
                  this.Controls.Add(radioButtons[i]);
              }
          }
  </code></pre>