protected void DropDownList1_SelectedIndexChanged(object sender, EventArgs e) { string[] CarArray = new string[4] {"Ford", "Honda", "BMW", "Dodge"}; string[] AirplaneArray = new string[3] {"Boeing 777", "Boeing 747", "Boeing 737"}; string[] TrainArray = new string[3] {"Bullet Train", "Amtrack", "Tram"}; if (DropDownList1.SelectedValue == "Car") { DropDownList2.DataSource = CarArray; } else if (DropDownList1.SelectedValue == "Airplane") { DropDownList2.DataSource = AirplaneArray; } else { DropDownList2.DataSource = TrainArray; } DropDownList2.DataBind(); DropDownList2.Visible = true; } protected void Button1_Click(object sender, EventArgs e) { Response.Write("You selected " + DropDownList1.SelectedValue.ToString() + ": " + DropDownList2.SelectedValue.ToString() + ""); } ]]>