Unable to set focus to java window from a C window...
My application has both C and Java as front end. I want to transfer focus from C window to Java window. But when I call frame.toFront() for my JAVA window... It just blinks in the windows bar... it doesn't come in focus.... Is there some windows setting preventing my wondow to come in focus? I am using java 1.5 on windows XP.
Please help ASAP... Txs.
[367 byte] By [
Rohan_Ka] at [2007-11-26 18:08:41]

# 1
What you're asking for is not a normal window behavior.
Windows should not appear suddenly on top of other windows.
From a user perspective it can be very annoying when you're in the middle of using some application and another application window decides to pop up infront of you.
But if you need this anyway, the only way I know is to use the setAlwaysOnTop method.
frame.setAlwaysOnTop(true);
frame.setAlwaysOnTop(false);