Own IWBasic 2.x ? -----> Get your free upgrade to 3.x now.........
Started by Andy, November 23, 2018, 03:57:14 am
0 Members and 1 Guest are viewing this topic.
int NoFocus = 0int hwndx,hwndy
hwndx = GetForegroundWindow() '<------- this lineWAITUNTIL win = 0 end
hwndy = GetForegroundWindow()'The program is not the one in focusif hwndx <> hwndy NoFocus = 1endif'The prgram is now back in focusif NoFocus = 1 and hwndx = hwndy NoFocus = 0 setfocus win,ListViewendif