java.lang.StringIndexOutOfBoundsException: String index out of range: 31

Coderanch | Paul Baker | 2 decades ago
tip
Do you find the tips below useful? Click on the to mark them and say thanks to rafael . Or join the community to write better ones.
  1. 0

    loops

    Coderanch | 2 decades ago | Paul Baker
    java.lang.StringIndexOutOfBoundsException: String index out of range: 31
  2. 0
    samebug tip
    Thrown by String methods to indicate that an index is either negative or greater than the size of the string. For some methods such as the charAt method, this exception also is thrown when the index is equal to the size of the string.
  3. 0

    java.lang.StringIndexOutOfBoundsException: String index out of range: 49

    Oracle Community | 2 decades ago | 843829
    java.lang.StringIndexOutOfBoundsException: String index out of range: 49
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    StringIndexOutOfBoundsException when attempting to view some classes

    Eclipse Bugzilla | 1 decade ago | william.whittle
    java.lang.StringIndexOutOfBoundsException: String index out of range: 21
  6. 0

    Sometimes impl. gen. show exception dialog

    Netbeans Bugzilla | 2 decades ago | issues
    java.lang.StringIndexOutOfBoundsException: String index out of range: 4002

  1. linxiaolong 1 times, last 1 month ago
  2. jokester 1 times, last 1 month ago
  3. tyson925 1 times, last 2 months ago
  4. Torasque 1 times, last 3 months ago
  5. Hronom 32257 times, last 3 months ago
11 more registered users
18 unregistered visitors
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. java.lang.StringIndexOutOfBoundsException

    String index out of range: 31

    at java.lang.String.charAt()
  2. Java RT
    String.charAt
    1. java.lang.String.charAt(String.java:516)
    1 frame
  3. Unknown
    A2Q3.main
    1. A2Q3.charCount(A2Q3.java:94)
    2. A2Q3.getInformation(A2Q3.java:59)
    3. A2Q3.main(A2Q3.java:113)
    3 frames