RadGridView LostFocus raised by mouse wheel

0 Answers 53 Views
GridView
Daniel
Top achievements
Rank 1
Iron
Daniel asked on 24 Jun 2024, 06:46 AM | edited on 24 Jun 2024, 07:06 AM
I have to react to the RadGridView's LostFocus event with a handler. Unfortunately, I discovered that the event is also triggered at unexpected times. What is particularly surprising is that scrolling with the scroll bar has no effect, but scrolling with the mouse wheel immediately calls the handler. And it does this without clicking the mouse and leaving the control. What could be the reason for this, or how can I get around it? The actual case that should be reacted to is when either another item of it is selected or the entire RadGridView loses focus by focusing on a control outside of it. Simply checking e.OriginalSource.GetType() == typeof(GridViewCell) doesn't help here either, as this is often the case when clicking on another control. And IsScrolling is also constantly false.Does anyone have any ideas?
Dimitar
Telerik team
commented on 24 Jun 2024, 09:07 AM

Hi Daniel, 

I was not able to reproduce the observed behavior on my end. For convenience, I prepared a small sample, based on the information that you provided so far and attached it to this thread. 
Could you please check it and let me know how it differs from your real setup? 

Thank you in advance for your patience and cooperation. 

Daniel
Top achievements
Rank 1
Iron
commented on 24 Jun 2024, 09:56 AM

I opened the solution with Visual Studio 2022, but the Telerik dependency could not be found. Also the .NET framework used by me is only 4.7 and Telerik is integrated by references to the DLLs with runtime version v4.0.30319.
Dimitar
Telerik team
commented on 25 Jun 2024, 05:38 AM

Hi Daniel, 

I am using the NuGet package that contains all assemblies which is easier for such cases:  Available NuGet Packages. Feel free to reference the assemblies in any way suitable for you, I am only interested in the code that I need to change in order to reproduce this. In addition, the project is NET7, and the references should be for this version, for example, 2024.2.514.70.

I am looking forward to your reply.

No answers yet. Maybe you can help?

Tags
GridView
Asked by
Daniel
Top achievements
Rank 1
Iron
Share this question
or