View Single Post
Old Jun 1st, 2006, 10:29 PM   #1
Eric the Red
Hobbyist Programmer
 
Eric the Red's Avatar
 
Join Date: Feb 2006
Posts: 214
Rep Power: 0 Eric the Red is an unknown quantity at this point
Quick question.. really Quick

I'm using the following code:

System.out.println ("position: " + fileData [i].indexOf ("<GPieceSize>"));

I'm getting an error saying that there's a null pointerException. How is this possible?

if the value isn't found within the string then a (-1) should be printed. Does anyone understand why there's a null pointer exception?
__________________
Death smiles at us all. All a man can do is smile back.
Eric the Red is offline   Reply With Quote