HI
There are a couple of comBobox named comBobox1 and comBobox2, and there is a SelectIndexChanged event for comBobox1.when this event fired,value (text as well) in comBobox2 shloud be changed as value in comBobox1 was changed. Here i get a problem,when the event occured,text in comBobox2 always the old one(even if it did not exist in the new datasourse),it did not refresh, and i need to delete the old text manually.
Is there any way to resolve it? Following is the demo
Best regards
There are a couple of comBobox named comBobox1 and comBobox2, and there is a SelectIndexChanged event for comBobox1.when this event fired,value (text as well) in comBobox2 shloud be changed as value in comBobox1 was changed. Here i get a problem,when the event occured,text in comBobox2 always the old one(even if it did not exist in the new datasourse),it did not refresh, and i need to delete the old text manually.
Is there any way to resolve it? Following is the demo
| protected void ddlMfg_SelectedIndexChanged(object sender, EventArgs e) |
| { |
| int mfg; |
| if (int.TryParse(this.ddlMfg.SelectedValue, out mfg)) |
| { |
| this.ddlBrandedLabel.Items.Clear(); |
| this.ddlBrandedLabel.DataSource = ProductStatus.ProductBrandedLabel_SelectAll_ByMfgId_AsDataSet(mfg, 0, 9); |
| this.ddlBrandedLabel.DataBind(); |
| } |
| else |
| { |
| ddlBrandedLabel.Items.Clear(); |
| } |
| } |
Best regards