1-888-365-2779
+1-888-365-2779
Try Now
More in this section

Forums / Developing with Sitefinity / Error trying to add Delegate to RadComboBox

Error trying to add Delegate to RadComboBox

3 posts, 1 answered
  1. andersleet
    andersleet avatar
    155 posts
    Registered:
    03 Jun 2009
    03 Jul 2009
    Link to this post
    I am trying to add an event handler to RadComboBox (selected index changed). Here is my code thus far:

    http://i41.tinypic.com/5bcift.jpg (screenshot show code + error)

    Any ideas?

    Thanks!
    anders
  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    16 Jun 2017
    03 Jul 2009
    Link to this post
    Hello andersleet,


    The event should look as below:

    void combo_SelectedIndexChanged(object o, RadComboBoxSelectedIndexChangedEventArgs e) 

    not ( ...... EventHandler e).

    Sample code:

    combo.SelectedIndexChanged += new RadComboBoxSelectedIndexChangedEventHandler(combo_SelectedIndexChanged); 
     
     
    ....... 
     
     
      void combo_SelectedIndexChanged(object o, RadComboBoxSelectedIndexChangedEventArgs e) 
        { 
     
           // code here 
        } 

    I hope this helps.

    Regards,
    Ivan Dimitrov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
    Answered
  3. andersleet
    andersleet avatar
    155 posts
    Registered:
    03 Jun 2009
    03 Jul 2009
    Link to this post
    Ah, haha. I feel dumb now :P.

    Thanks Ivan!

    Regards,
    anders
Register for webinar
3 posts, 1 answered