Clicking on a button after checking check box in MultiselectionComboBox does not trigger button's click event

3 posts, 0 answers
  1. Victor
    Victor avatar
    1 posts
    Member since:
    Feb 2012

    Posted 28 Jan Link to this post

    Hi,

     I am trying to use RadComboBox with check box items - using this MultiselectionComboBox http://www.telerik.com/forums/multi-select-combobox-column-b1333dcb19e7#A84Ijx2y90Cke9PV3xKCOA

    Then I added a button to this view and after checking some check boxes I click on this button - nothing happens and I need to click on it second time in order to trigger the desired action.

    Looks like one click is "wasted" on closing the combobox. Is there any way to prevent this so that after checking any check box in combobox clicking on the button will actually trigger button click event?

    Thanks

    Victor

     

  2. Nasko
    Admin
    Nasko avatar
    587 posts

    Posted 01 Feb Link to this post

    Hi Victor,

    The observed behavior is not related with RadComboBox, but it is one caused by the Framework itself - if you replace RadComboBox with the native WPF ComboBox the exact same behavior will be observed. However, still we were able to find an approach that could help you achieve the desired - please, check the following link:
    http://stackoverflow.com/questions/9710013/how-to-get-a-combobox-to-appropriately-set-focus-directly-after-the-popup-closes

    Basically, it demonstrates how to move the focus to the Button when the Popup gets clicked. We have also modified the sample you sent us with it and it seems it works as expected - attached you could find the modified project.

    We hope this will help you.

    Regards,
    Nasko
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  3. UI for WPF is Visual Studio 2017 Ready
  4. Victor
    Victor avatar
    1 posts
    Member since:
    Jan 2016

    Posted 01 Feb Link to this post

    Thank you.

    I thought so but wanted to see if you have any good solution. And it works.

    Actually, I had this before asking you:

             private void RadComboBox_OnDropDownClosed(object sender, EventArgs e)

            {
                if (BtnClickMe.IsMouseOver)
                {
                    Button_Click(sender, null);
                }
            }

    and it works too.

    Thanks again.

    Victor

Back to Top