I am building a UWP app for a RPi3 with touchsreen. I have a textbox that I give focus to on page load. I don't want to lose that focus if a user touches another control on the page, except for two specific buttons. I am using this textbox for scanner input.
I've tried disabling different properties for the controls I don't want to get focus:
AllowFocusOnInteraction="False" IsDoubleTapEnabled="False" IsHitTestVisible="False" IsHoldingEnabled="False" IsRightTapEnabled="False" IsTapEnabled="False"
But if I press any of those controls, the textbox stills loses focus.
I've also tried an event handler for textbox_LostFocus to re-give it focus, however this stops the user from clicking one the 2 buttons the user needs to click (the only controls who should receive focus) as the textbox_LostFocus event fires again to set the focus back to the textbox before the button_Click event can fire.
In a winform, I would have disabled the tabstop property. Any ideas for UWP?
Thanks in advance.