urgent question about focus Jtextfield.

10 views
Skip to first unread message

Kurt Latre

unread,
Nov 25, 2011, 10:14:45 AM11/25/11
to AsWing Discuss
I have a flash application that is working together with another
webcam-application (quickmark)
The webcam-application is capable of sending information to flash in
the form of keyboard input.
But unfortunally the Key-events are not recognised by as3 (neither
the key-up or key-down)

The only thing that is working is when i have a JTextfield, and i
click in it, than the webcamapplication sends its info correctly.
I spend hours now to find out how i can have the JTextfield keep focus
all the time, but without any luck.
I tried the focusmanager, but i always get errors. I think I'm
confused in how the focusmanager works.
I also tried stage.focus = TheTextfield, but it produces also the
error.

Can somebody provide me with working code that automaticly focusses a
JTextfield
I hope someone can, because i have to deliver a project this weekend.

best regards
Kurt

Kurt Latre

unread,
Nov 25, 2011, 2:23:20 PM11/25/11
to AsWing Discuss
Found a solution.
seemed like i called the requestFocus before the component was ready
I used a timer to call the requestFocus at an interval.
Now it works
Reply all
Reply to author
Forward
0 new messages