Setting SelectedIndex = -1 doesn't clear contents

17 posts, 1 answers
  1. Chris
    Chris avatar
    53 posts
    Member since:
    Oct 2012

    Posted 22 Apr 2009 Link to this post

    I haven't seen any resolutions to this issue in the forum, however, I'm running into an issue where setting the SelectedIndex of the RadComboBox to -1 doesn't clear the contents. 

    After setting it, I checked the value of the Text property and the SelectedItem property in the Immediate window, the text returns "" and the SelectedItem returns null, however when the screen is displayed, the first items in the RadComboBox are displayed.

    Should this not clear the values displayed as well?  Am I doing something wrong?

    Thanks in advance

    Chris
  2. Kaloyan
    Admin
    Kaloyan avatar
    920 posts

    Posted 23 Apr 2009 Link to this post

    Hi Chris,

    We found and fixed this problem earlier this week. A new internal build that contains the fix will be released tomorrow, you will be able to find it at the following page (you need to be logged-in in order to visit it):
    http://www.telerik.com/account/downloads/internal-builds.aspx

    Best wishes,
    Kaloyan
    the Telerik team

    Instantly find answers to your questions on the newTelerik Support Portal.
    Check out the tipsfor optimizing your support resource searches.
  3. Chris
    Chris avatar
    53 posts
    Member since:
    Oct 2012

    Posted 23 Apr 2009 Link to this post

    Hi Kaloyan,

    I'm sorry, I should have been more specific.  I'm having this issue with Silverlight 2.0.

    Regards,

    Chris
  4. Valeri Hristov
    Admin
    Valeri Hristov avatar
    2252 posts

    Posted 23 Apr 2009 Link to this post

    Hi Chris,

    The fix Kaloyan is talking about is for RadComboBox for Silverlight 2. Currently there are no internal builds for RadControls for Silverlight, hence the message on the "Internal Builds" page.

    I apologize for the misunderstanding.

    Greetings,
    Valeri Hristov
    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.
  5. Chris
    Chris avatar
    53 posts
    Member since:
    Oct 2012

    Posted 23 Apr 2009 Link to this post

    Hi Valeri,

    I went to the link and copied the files in the following zip file RadControls_For_Silverlight3_Trial_2009.3.27.zipwhich was at the download link that Kaloyan specified.  After copying them (I was a bit hasty and didn't see the filename) and trying my app, I didn't see any change (ie. it didn't fix the issue) so I went back to the download site and then realized based on the name that this is the Silverlight3 trial code (based on the filename). 

    Did I retrieve the wrong file? 

    Thanks in advance

    Chris
  6. Valeri Hristov
    Admin
    Valeri Hristov avatar
    2252 posts

    Posted 23 Apr 2009 Link to this post

    Hi Chris,

    The "internal build" that will contain the RadComboBox fix will be available tomorrow. Right now there are no builds that resolve the bug you have found. I will post here again when we are ready.

    Kind regards,
    Valeri Hristov
    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.
  7. Chris
    Chris avatar
    53 posts
    Member since:
    Oct 2012

    Posted 27 Apr 2009 Link to this post

    Hi Valeri,

    Is the new build available?

    Regards,

    Chris
  8. Valeri Hristov
    Admin
    Valeri Hristov avatar
    2252 posts

    Posted 27 Apr 2009 Link to this post

    Hi Chris,

    Yes, you should be able to see it at:
    http://www.telerik.com/account/downloads/internal-builds.aspx

    If the page still says that there are no builds for Silverlight, you should download (or at least begin to download) any of the trial installations. This is needed because the system automatically detects what are the products you downloaded in the past and provides only the related builds.

    Best wishes,
    Valeri Hristov
    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.
  9. Chris
    Chris avatar
    53 posts
    Member since:
    Oct 2012

    Posted 27 Apr 2009 Link to this post

    Hi Valeri,

    Perhaps I'm doing something wrong, but it doesn't appear to be fixed.  I selected the ZIP file from the location and copied the files into the directory where the binaries were installed (C:\Program Files\Telerik\RadControls for Silverlight Q1 2009\Binaries\Silverlight).  (Visual Studio was closed at the time).

    I then re-opened my project.  A value was selected from my dropdown.  When I then pressed the button that clears the fields (and sets the SelectedIndex = -1 for RadComboBoxes), my combo boxes still displayed a value rather than displaying nothing (even though the SelectedItem is null).

    Am I doing something wrong?  

    Regards,

    Chris

  10. Valeri Hristov
    Admin
    Valeri Hristov avatar
    2252 posts

    Posted 27 Apr 2009 Link to this post

    Hi Chris,

    Did you rebuild the project before running? Probably the assemblies were not updated by Visual Studio? You may also try to re-add the references to the Telerik assemblies if the rebuild does not help. The correct assembly version of all Telerik assemblies is:
    2009.1.0424.1020

    I am attaching a simple application that has two combo boxes, one data-bound and one with static items. It demonstrates the bug we fixed. Please, let me know if your problem is different.

    Sincerely yours,
    Valeri Hristov
    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.
  11. Chris
    Chris avatar
    53 posts
    Member since:
    Oct 2012

    Posted 27 Apr 2009 Link to this post

    Hi Valeri,

    It still happens, but it happens when the following 2 properties are set: 

    IsEditable="True" IsReadOnly="True"

    Setting SelectedIndex = -1 displays the first item in the dropdown.

    Regards,
    Chris
  12. Answer
    Valeri Hristov
    Admin
    Valeri Hristov avatar
    2252 posts

    Posted 28 Apr 2009 Link to this post

    Hello Chris,

    Thank you for the clarification. I found and fixed the new problem. Please, find attached the updated binaries and let me know if they don't work for you.

    All the best,
    Valeri Hristov
    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.
  13. Chris
    Chris avatar
    53 posts
    Member since:
    Oct 2012

    Posted 28 Apr 2009 Link to this post

    Thanks Valeri, that fixed the issue.
  14. TonyG
    TonyG avatar
    239 posts
    Member since:
    Feb 2006

    Posted 10 May 2009 Link to this post

    I was just struggling with this issue in the ASP.NET Ajax library. I put myCombo.ClearSelection() calls all over the place until the thing finally cleared.  :)   Is this a recognized issue in the Ajax library as well as Silverlight?
  15. Valeri Hristov
    Admin
    Valeri Hristov avatar
    2252 posts

    Posted 11 May 2009 Link to this post

    Hello TonyG,

    I suppose that ASP.NET AJAX RadComboBox might contain similar bug. The best way to confirm it is to ask in the ASP.NET AJAX forums, or write a support ticket. Don't forget to attach a simple sample application that demonstrates the problem - this way you will get the fastest and most accurate response.

    Regards,
    Valeri Hristov
    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.
  16. Jonathan Miller
    Jonathan Miller avatar
    57 posts
    Member since:
    Jun 2008

    Posted 12 May 2009 Link to this post

    Is this fix included in the internal builds?
  17. Valeri Hristov
    Admin
    Valeri Hristov avatar
    2252 posts

    Posted 13 May 2009 Link to this post

    Hello Jonathan,

    The changes in the attached binaries are included in the latest internal builds.

    Regards,
    Valeri Hristov
    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.
Back to Top