This is a migrated thread and some comments may be shown as answers.

[Solved] radcombobox 'e.Context error'

4 Answers 106 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
Afo
Top achievements
Rank 1
Afo asked on 10 Dec 2009, 10:56 PM
I have 5 comboboxes and I need to filter 4 of them based on what was selected in the 5th one. I have implemented this based on the example here:
http://www.telerik.com/community/forums/aspnet-ajax/combobox/related-comboboxes-server-side.aspx

It works for the 1st combobox but not for the other 3. I keep on getting 'The given key was not present in the dictionary.'. Can you show an example of filtering 4 comboboxes based on selected value of 1 combobox.
thanks.

4 Answers, 1 is accepted

Sort by
0
Simon
Telerik team
answered on 11 Dec 2009, 01:05 PM
Hi Afo,

Please make sure that you are handling the client-side ItemsRequesting event of all RadComboBoxes after the first and you are using exactly the same key (e.g. previousComboBoxValue) in the server-side ItemsRequested event handler when accessing the Context object there.

Greetings,
Simon
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Afo
Top achievements
Rank 1
answered on 11 Dec 2009, 01:14 PM
I am...but in case I'm missing something, can you show me a code sample.
thanks.
0
Simon
Telerik team
answered on 11 Dec 2009, 01:28 PM
Hello Afo,

Please see the code sample provided in the referred forum thread - http://www.telerik.com/community/forums/aspnet-ajax/combobox/related-comboboxes-server-side.aspx.

In your case you need to do the same configuration for each subsequent pair after the first one:
  • RCB2: ItemsRequesting gets the value of RCB1;
  • RCB3: ItemsRequesting gets the value of RCB2;
  • ...etc.
If you still experience the issue, please paste here the definitions of your RadComboBoxes as well as their client-side and server-side event handlers' code (ItemsRequesting and ItemsRequested).

Regards,
Simon
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Afo
Top achievements
Rank 1
answered on 12 Dec 2009, 05:23 AM
ok, thanks... that works.
Tags
ComboBox
Asked by
Afo
Top achievements
Rank 1
Answers by
Simon
Telerik team
Afo
Top achievements
Rank 1
Share this question
or