title: Conditionally Show/Hide Windows Form Elements
body: <p>I am trying to make a simple Windows Form application that will show different options based on the values of preceding elements - for example I have four radio buttons at the top of the form, each one will show and hide elements various other elements within the form - essentially making several forms in one.</p>
  
  <p>I have this set up in a large conditional statement (this is only a small portion, but it is all similar):</p>
  
  <pre><code>private void Payment_Load(object sender, EventArgs e)
    {
              if (rdoMultChoice.Checked)
              {
  
                  lblGroupBox1_MC.Visible = true;
                  lblGroupBox1_FITB.Visible = false;
                  lblGroupBox1_TF.Visible = false; 
               // etc...
              }
              else if (rdoFillInBlank.Checked)
              {
                  lblGroupBox1_MC.Visible = false;
                  lblGroupBox1_FITB.Visible = true;
                  lblGroupBox1_TF.Visible = false;
               // etc...
              }
  </code></pre>
  
  <p>The problem is, when I run the application the form completely ignores these statements and appears to just make all of my elements visible. </p>
  
  <p><a href="http://msdn.microsoft.com/en-us/library/754w18dd.aspx" rel="nofollow">http://msdn.microsoft.com/en-us/library/754w18dd.aspx</a></p>
  
  <p>This link is sort of similar to my needs. I tried to adapt it to my situation but it didn't appear to work (can't guarantee that I did it correctly...). </p>
  
  <p>Seems like this should be a really simple thing to do but I am new to C# and only started using it this week - an assignment for a CS class. Just to rant, we are expected to develop "expertise" in 13 languages in 15 weeks! With very few resources provided by the university, so far the only expertise I have developed is in searching documentation and stack overflow! :)</p>