I'm adding items to a RadComboBox server-side like so:
Then later I'm selecting the item I want to be initially selected in the combobox on the server-side too:
I have registered a client-side event listener to the "OnClientSelectedIndexChanged" event. However, this event seems to be firing as soon as the page loads as if the user has selected a value using the combobox. Is this expected behaviour, something broken or me doing something wrong? I only want to be notified when the value has been changed by the user from the value selected server-side - how would I achieve this?
I am using version 2008.3.1314.20
Thanks,
James
Addendum: I've just realised that the client event only seems to be fired once when the page loads and never again. That is, the event is not being fired when the user selects a new item. Help!
| foreach (ValueMapping mapping in ValueMappings) |
| { |
| RadComboBoxItem comboItem = new RadComboBoxItem(mapping.DisplayValue, mapping.DataValue); |
| this.Items.Add(comboItem); |
| } |
Then later I'm selecting the item I want to be initially selected in the combobox on the server-side too:
| RadComboBoxItem item = |
| this.FindItemByValue(value); |
| if (item != null) |
| { |
| item.Selected = true; |
| } |
I have registered a client-side event listener to the "OnClientSelectedIndexChanged" event. However, this event seems to be firing as soon as the page loads as if the user has selected a value using the combobox. Is this expected behaviour, something broken or me doing something wrong? I only want to be notified when the value has been changed by the user from the value selected server-side - how would I achieve this?
I am using version 2008.3.1314.20
Thanks,
James
Addendum: I've just realised that the client event only seems to be fired once when the page loads and never again. That is, the event is not being fired when the user selects a new item. Help!