Note that there are some explanatory texts on larger screens.

plurals
  1. POcannot see the label content when a item is selected from dynamically added dropdownlist
    primarykey
    data
    text
    <p>I have a Dropdownlist (DDL1) when I select any item from this dropdownlist(DDL1), results in creation of another dropdownlist(DDL2), This contains some of the items.When I select other Item from DDL1 , Items will change in DDL2, this happens for the each different item selected in DDL1. </p> <p>when I select a item from DDL2, label content must be shown, intially I'm making Label invisibe and in the code I changed the visibility to true and added content to it. But the label content is not shown when I select a item from DDL2.</p> <p>Here is my Code</p> <pre><code>protected void DropDownList1_SelectedIndexChanged(object sender, EventArgs e) { if (DropDownList1.SelectedValue == "Abe Books") { DropDownSeller.Visible = true; lnkUsdBooks.Visible = true; lnkUsdBooks.Text = "usedbooks@abe.com"; lnkUsdBooks.NavigateUrl = "mailto:usedbook@abe.com"; DropDownSeller.Visible = true; DropDownSeller.Items.Remove("Chacha Choudary"); DropDownSeller.Items.Remove("SpiderMan"); DropDownSeller.Items.Remove("Amar chitra Katha"); DropDownSeller.Items.Remove("Chandamama"); DropDownSeller.Items.Remove("Mahabharata"); DropDownSeller.Items.Add("Amar chitra Katha"); DropDownSeller.Items.Add("Chandamama"); DropDownSeller.Items.Add("Mahabharata"); DropDownSeller.DataBind(); if (DropDownSeller.SelectedValue == "Amar chitra Katha") { lblPrice.Visible = true; lblPrice.Text = "$69.99"; } else if (DropDownSeller.SelectedValue == "Chandamama") { lblPrice.Visible = true; lblPrice.Text = "$59.99"; } else if (DropDownSeller.SelectedValue == "Mahabharata") { lblPrice.Visible = true; lblPrice.Text = "$49.99"; } else { lblPrice.Visible = false; } } </code></pre> <p>Any ideas on this are appreciated</p> <p>Thanks,</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload