S
Sameer
A simple chatting system i am dealing with is as follows:
The Client accepts text in a TextField and sends it to a server.
Server sends it to all the connected clients.
The message received by Client is appended to a JTextPane.
This works fine
I have written one special client in which using the 'Robot' class of
AWT, It automatically enters the text 'TESTING' in the TextField and
let it press the Enter key. The Testing method is set to run in an
indefinite loop so that this Client will send this message continuosly
after some delay.
This mechanism also works....
but the problem is that when this is happening on the screen, the other
components of the system like JList, contents of JTextPane are not
displayed. It just shows the text being typed in the TextField but the
rest GUI is not updatable.
I tried using
jtextpane.updateUI();
jtextpane.validate();
SwingUtilities.updateComponentTreeUI(Component c)
but it wont work.
What may be the problem?
Please help.
-Sameer
The Client accepts text in a TextField and sends it to a server.
Server sends it to all the connected clients.
The message received by Client is appended to a JTextPane.
This works fine
I have written one special client in which using the 'Robot' class of
AWT, It automatically enters the text 'TESTING' in the TextField and
let it press the Enter key. The Testing method is set to run in an
indefinite loop so that this Client will send this message continuosly
after some delay.
This mechanism also works....
but the problem is that when this is happening on the screen, the other
components of the system like JList, contents of JTextPane are not
displayed. It just shows the text being typed in the TextField but the
rest GUI is not updatable.
I tried using
jtextpane.updateUI();
jtextpane.validate();
SwingUtilities.updateComponentTreeUI(Component c)
but it wont work.
What may be the problem?
Please help.
-Sameer