exception while event processing
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   pushkar_prakash
Posted On:   Sunday, March 30, 2003 10:32 AM

Hi, Everyone . I am having problem with event processing in JApplet ( on win2k server,java plugin in ie). I have this network client JApplet which has some JButtons .If one button is clicked then only that button will respond for next clicks,and if any other button is clicked then the applet hangs(the button remains in depressed position). (The applet read and writes java objects over the network.) I am getting this stack trace in the java console window. java.util.NoSuchElementException at java.util.LinkedList.getFirst(LinkedList.java:101) at java.awt.SequencedEvent.getFirst(SequencedEvent.j   More>>

Hi, Everyone .
I am having problem with event processing in JApplet (

on win2k server,java plugin in ie).

I have this network client JApplet which has some
JButtons .If one button is clicked then only that

button will respond for next clicks,and if any other

button is clicked then the applet hangs(the button remains

in depressed position).


(The applet read and writes java objects over the network.)


I am getting this stack trace in the java console window.




java.util.NoSuchElementException

at java.util.LinkedList.getFirst(LinkedList.java:101)

at java.awt.SequencedEvent.getFirst(SequencedEvent.java:126)

at java.awt.SequencedEvent.dispatch(SequencedEvent.java:68)

at java.awt.EventQueue.dispatchEvent(EventQueue.java:448)

at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:197)

at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:150)

at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:144)

at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:136)

at java.awt.EventDispatchThread.run(EventDispatchThread.java:99)



prakash,

bangalore.

   <<Less

Re: exception while event processing

Posted By:   Brian_Glodde  
Posted On:   Sunday, March 30, 2003 06:55 PM

From the JavaDoc:


java.util.NoSuchElementException

Thrown by the nextElement method of an Enumeration to indicate that there are no more elements in the enumeration.


Are you checking the size of your LinkedList before attempting to iterate?

About | Sitemap | Contact