I have two dropdownlists on an ascx control (ddlItemCode and ddlItemDescr).
They both have the same data as source. The only difference is the the fist one shows the code and the other one the description of the item.
In the code behind:
ddlItemCode.Attributes.Add("onChange", "return ddlcodeOnSelectedIndexChange(this,'ddlItemCode');")
and for both lists...
ddlItemxxxx.DataValueField = "Itm_ID"
When the page opens, both lists have Itm_ID = 1853
(so the attached screen image below makes some sense)
On the shown script, I am trying to synchronize the right list (ddlItemDescr), so it selects the item which is selected on left list (ddlItemCode).
As you see on the screen image, the user selects the third entry (Itm_ID = 1857), but right list remains on the first selection. The watch expressions have been updated when the code reached the breakpoint.
In simple words, the command ddlto.val(newvalue) does not work!
Although it sounds stupid, I did try ddlto.val("1857") in the code just to check and still there was no change.
I would appreciate any help...
They both have the same data as source. The only difference is the the fist one shows the code and the other one the description of the item.
In the code behind:
ddlItemCode.Attributes.Add("onChange", "return ddlcodeOnSelectedIndexChange(this,'ddlItemCode');")
and for both lists...
ddlItemxxxx.DataValueField = "Itm_ID"
When the page opens, both lists have Itm_ID = 1853
(so the attached screen image below makes some sense)
On the shown script, I am trying to synchronize the right list (ddlItemDescr), so it selects the item which is selected on left list (ddlItemCode).
As you see on the screen image, the user selects the third entry (Itm_ID = 1857), but right list remains on the first selection. The watch expressions have been updated when the code reached the breakpoint.
In simple words, the command ddlto.val(newvalue) does not work!
Although it sounds stupid, I did try ddlto.val("1857") in the code just to check and still there was no change.
I would appreciate any help...