Search:

Type: Posts; User: copeg

Search: Search took 0.09 seconds.

  1. Replies
    5
    Views
    1,187

    Re: String to Int messing up

    You should use equals, so don't change to ==. The exception (pun intended) is if there is a possibility that the string you wish to call equals on could be null, in which case you first check for...
  2. Replies
    5
    Views
    1,187

    Re: String to Int messing up

    Because rlinenumRead is not an object, it is null, so by definition a NullPointerException will be thrown. Try using
    if ( rlinenumRead == null )
    to check for a null value.
  3. Replies
    5
    Views
    1,187

    Re: String to Int messing up

    Note the readLine int DataInputStream is deprecated (BufferedReader is recommended). Also note that the readLine methods in the readers will return null if the end of the stream is reached.
Results 1 to 3 of 3