This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Other Java Products and Servers and the fly likes NoSuchElementException Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Products » Other Java Products and Servers
Bookmark "NoSuchElementException" Watch "NoSuchElementException" New topic
Author

NoSuchElementException

priya pratheepp
Ranch Hand

Joined: Apr 02, 2008
Posts: 59
Hi friends,

while retreving data from SAP i am getting error in log file

92[10]java.util.NoSuchElementException

174[10]java.util.NoSuchElementException

176[10]java.util.NoSuchElementException

217[10]java.util.NoSuchElementException

218[10]java.util.NoSuchElementException

392[10]java.util.NoSuchElementException

408[10]java.util.NoSuchElementException

etc


please help me to trace...any hints please

Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41034
    
  43
Before any call to nextToken, you should call hasMoreTokens to make sure that there are indeed more tokens.

Here the call to nextToken happens in a for loop, which -without calls to hasMoreTokens- is a bug waiting to happen.


Ping & DNS - my free Android networking tools app
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: NoSuchElementException
 
Similar Threads
exception doubt
srting doubt on ==
Strings...
Strings, StringBuffer and equals()
e.printStackTrace();