Page in WPF losing focus -


i have page in wpf has text box. text box set focused on load.

there application running in background takes string value of biometrics scan result , places in text box. 3rd party application, , have been told looks text box name, in application name , if text box focused on, write string in.

this works fine, below problem having.

we have piece of software custom on screen keyboard. text box can written user can click button bring keyboard start typing. when keyboard comes up, seems lose focus application , doesnt come again. lifecycle of our application running, biometrics doesn't work because doesn't see application 1 in focus.

how force application come in focus, when want to. don't want in focus , on top, else custom keyboard never show.

i looked application.activated event no joy, , tried following

public static extern bool setforegroundwindow(intptr hwnd);

getting stuck, have advice?

have tried activate() , focus() methods? thread has bunch of answers on topic bring window front in wpf

this particular 1 worked me https://stackoverflow.com/a/7559766/305020


Comments

Popular posts from this blog

c# - How Configure Devart dotConnect for SQLite Code First? -

java - Copying object fields -

c++ - Clear the memory after returning a vector in a function -