Focus between two RadMaskedTextInput freezes the application

3 posts, 1 answers
  1. Kristof Van Cauwenberghe
    Kristof Van Cauwenberghe avatar
    9 posts
    Member since:
    Apr 2010

    Posted 13 Oct 2016 Link to this post

    Our application uses RadMaskedTextInputs for user data input. When Enter is pressed, we perform field validation and focus the fields that need revising. If however two of these controls are focused one after the other, the application freezes. To test try the following:

    Create a WPF with two RadMaskedTextInputs

            <telerik:RadMaskedTextInput Width="100" Height="20" Margin="200,122,0,167" Name="txt1"></telerik:RadMaskedTextInput>
            <telerik:RadMaskedTextInput Width="100" Height="20" Margin="200,155,0,134" Name="txt2"></telerik:RadMaskedTextInput>

    On txt2 keyup event:

        Private Sub txt2_KeyUp(sender As Object, e As System.Windows.Input.KeyEventArgs) Handles txt2.KeyUp
            If e.Key = Key.Enter Then
            End If
        End Sub

    Run the application, type something in txt2 and press enter.


  2. Answer
    Dinko avatar
    537 posts

    Posted 17 Oct 2016 Link to this post

    Hello Kristof Van Cauwenberghe,

    Thank you for the provided information.

    We managed to reproduce the described behaviour on our side. We can confirm that this is a bug and therefore we logged it in our Feedback Portal where you can track its progress and vote for its implementation. By voting, you are increasing its priority. We have also updated your Telerik points for bringing this issue to our attention.

    As a workaround, you can use a Dispatcher to focused the controls.
    If e.Key = Key.Enter Then
        Dispatcher.BeginInvoke(New Action(Function()
    End Function), DispatcherPriority.Loaded)
    End If

    Give this approach a try and let us know if it works for you.

    Telerik by Progress
    Do you need help with upgrading your AJAX, WPF or WinForms project? Check the Telerik API Analyzer and share your thoughts.
  3. Kristof Van Cauwenberghe
    Kristof Van Cauwenberghe avatar
    9 posts
    Member since:
    Apr 2010

    Posted 17 Oct 2016 in reply to Dinko Link to this post

    Thanks for the info. I can confirm this workaround works for this particular case, however we would prefer a solution since in our application different pieces of code call the focus, and setting dispatchers on all of them would not be desirable. We will monitor the bug's progress as you suggested.
Back to Top