[UWP][C#] GotFocus and LostFocus events of TextBlock is not raised either by tab pressing or by mouse click RRS feed

  • Question

  • Hi,

    I want to perform some action on GotFocus and LostFocus events of a TextBlock but it is not raised by clicking on through mouse or by tab navigation. I want to raise these events on both of the input methods.

    Could you please let me know how to do so.

    Any help would be greatly appreciated!!!



    Thursday, December 8, 2016 7:03 AM


  • Hi Prashant,

    TextBlock is not is not focusable control. Tab navigation will work only if control is focusable. You can use Tap event. Alternately you can create button style to match your requirements. Button is  focusable control.


    Pallam Madhukar Windows Phone Developer

    Thursday, December 8, 2016 8:58 AM