This is a migrated thread and some comments may be shown as answers.

RadMaskedNumericInput and MouseWheel Event

2 Answers 42 Views
MaskedInput (Numeric, DateTime, Text, Currency)
This is a migrated thread and some comments may be shown as answers.
Ezequiel
Top achievements
Rank 1
Ezequiel asked on 18 Mar 2014, 04:53 PM
Hi there!

When i'm over RadMaskedNumericInput control the scroll screen not work. In short, RadMaskedNumericInput's MouseWheel Event no trigger although the control is set  <telerik:RadMaskedNumericInput SpinMode="None"/>

Thank you.
Best regards.


2 Answers, 1 is accepted

Sort by
0
Boris
Telerik team
answered on 21 Mar 2014, 03:01 PM
Hello Ezequiel,

The RadMaskedInputControls handle internally the MouseWheel event and that is why this event does not fire when you subscribe for it. A possible way to trigger the MouseWheel event of the RadMaskedNumericInput is to inherit its class and override the OnMouseWheel() method.

public class CustomMaskedNumericInput : RadMaskedNumericInput
   {
       protected override void OnMouseWheel(MouseWheelEventArgs e)
       {
       }       
   }

I attached a sample project that demonstrates the suggested approach. When you run the example you will see that in XAML there are several Buttons and the CustomMaskedNumericInput wrapped in a ScrollViewer. This is done to demonstrate that the MouseWheel event will trigger the scrolling of the ScrollViewer even when the CustomMaskedNumericInput is focused.

However, we are not entirely sure what you are trying to achieve. If this is not exactly your case could you please elaborate a bit more on it ?

Regards,
Boris Penev
Telerik
 

Build cross-platform mobile apps using Visual Studio and .NET. Register for the online webinar on 03/27/2014, 11:00AM US ET.. Seats are limited.

 
0
Ezequiel
Top achievements
Rank 1
answered on 21 Mar 2014, 04:36 PM
It works! 

Thank you so much for your support! 
Tags
MaskedInput (Numeric, DateTime, Text, Currency)
Asked by
Ezequiel
Top achievements
Rank 1
Answers by
Boris
Telerik team
Ezequiel
Top achievements
Rank 1
Share this question
or