RadComboBox SelectedItem and SelectedProperty Issue

2 posts, 0 answers
  1. Ashish
    Ashish avatar
    12 posts
    Member since:
    Aug 2012

    Posted 07 Sep 2012 Link to this post

    Hello Telerik Team,

    I have used RadCombox in my site extensively, and also I have used the “EmptyMessage” property. Recently I have updated the Telerik version to “2012.2.724.35” and after that i am facing too many issues related to RadCombox.

    Older Version we were using: 2011.1.519.35
    New Version currently we are using: 2012.2.724.35

    In Telerik “2012.2.724.35” version, i have used the following RadComboBox In my web page. Now the issue is, if I do not change the default selection of following ddlStatus i.e. the ddlStatus is set to “-Select One-” and when I trying to access the “SelectedItem” property of ddlStatus from code behind, then it gives a null value whereas with the previous telerik version (2011.1.519.35), if the ddlStatus is set to default selection i.e. “-Select One-” and if I trying to access the “SelectedItem” property of ddlStatus then it gives the object of 0th position item i.e. <telerik:RadComboBoxItem Text="" Value="0" />. Besides that, in “2012.2.724.35” version, for the default selection of ddlStatus, the ddlStatus.SelectedValue property gives the Empty string where as in older version(2011.1.519.35) it gives the value of 0th element i.e. "0".   

    <telerik:RadComboBox ID="ddlStatus" runat="server" Width="60px" EmptyMessage="-Select one-">


                  <telerik:RadComboBoxItem Text="" Value="0" />

                  <telerik:RadComboBoxItem Text="No" Value="1" />

                  <telerik:RadComboBoxItem Text="Yes" Value="2" />




    This changed behavior of RadComboBox encounters so many issues in my website. Is there any generic way to resolve this issue?

    Please suggest the workaround to resolve this issue.



  2. Cat Cheshire
    Cat Cheshire avatar
    128 posts
    Member since:
    Jun 2010

    Posted 12 Sep 2012 Link to this post

    You can try setting the first RadComboBoxItem Text to space(" ") instead of empty string.
Back to Top