java.lang.StringIndexOutOfBoundsException: length=5; index=5

Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Samebug tips

,
Expert 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.

,
via oracle.com by Unknown author

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.

Solutions on the web

via JIRA by Vitaliy Filippov, 1 year ago
String index out of range: 0
via Stack Overflow by Raymond Edde
, 1 year ago
java.lang.StringIndexOutOfBoundsException: length=5; index=5
at java.lang.String.charAt(Native Method)
at org.dmfs.tasks.model.adapters.DescriptionStringFieldAdapter.extractDescription(DescriptionStringFieldAdapter.java:114)
at org.dmfs.tasks.model.adapters.DescriptionStringFieldAdapter.get(DescriptionStringFieldAdapter.java:62)
at org.dmfs.tasks.widget.TextFieldEditor.onContentChanged(TextFieldEditor.java:134)
at org.dmfs.tasks.model.ContentSet.notifyUpdateListeners(ContentSet.java:601)
at org.dmfs.tasks.model.ContentSet.put(ContentSet.java:438)
at org.dmfs.tasks.model.adapters.StringFieldAdapter.set(StringFieldAdapter.java:112)
at org.dmfs.tasks.model.adapters.DescriptionStringFieldAdapter.set(DescriptionStringFieldAdapter.java:88)
at org.dmfs.tasks.widget.TextFieldEditor.updateValues(TextFieldEditor.java:123)
at org.dmfs.tasks.widget.BaseTaskView.updateValues(BaseTaskView.java:113)
at org.dmfs.tasks.widget.BaseTaskView.updateValues(BaseTaskView.java:104)
at org.dmfs.tasks.EditTaskFragment.saveAndExit(EditTaskFragment.java:726)
at org.dmfs.tasks.EditTaskFragment.onOptionsItemSelected(EditTaskFragment.java:520)
at android.support.v4.app.Fragment.performOptionsItemSelected(Fragment.java:2070)
at android.support.v4.app.FragmentManagerImpl.dispatchOptionsItemSelected(FragmentManager.java:2159)
at android.support.v4.app.FragmentController.dispatchOptionsItemSelected(FragmentController.java:295)
at android.support.v7.app.AppCompatActivity.onMenuItemSelected(AppCompatActivity.java:147)
at android.support.v7.view.WindowCallbackWrapper.onMenuItemSelected(WindowCallbackWrapper.java:100)

Users with the same issue

6 times, 1 year ago
4 times, 4 months ago
6 times, 11 months ago
Once, 1 year ago
2 times, 1 year ago

Write tip

Know the solutions? Share your knowledge to help other developers to debug faster.