Beanie posted on October 27, 2009 18:49
   1:  protected void cboCountry_SelectedIndexChanged(object sender, EventArgs e)
   2:  {        
   3:      cboState.DataBind();
   4:      if (cboState.Items.Count != 0)
   5:      {
   6:          cboState.Visible = true;
   7:          ListItem li = new ListItem("No State", "0");
   8:          cboState.Items.Add(li);
   9:          cboState.SelectedIndex = cboState.Items.IndexOf(cboState.Items.FindByValue("0"));
  10:      }
  11:      else
  12:      {
  13:          cboState.Visible = false;
  14:      }
  15:  }

Posted in: Development , Development - ASP  Tags: , , ,

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Comments

Page List

Search Blog

Tag Cloud

Recent Comments

Disclaimer
The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

© Copyright 2012 Beanie