java.lang.StringIndexOutOfBoundsException

String index out of range: 7


Samebug tips1

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.

Don't give up yet. Our experts can help. Paste your full stack trace to get a solution.


Solutions on the web4541

Solution icon of bugzilla
via Eclipse Bugzilla by darryl, 1 year ago
String index out of range: 7

Solution icon of github
via GitHub by matiuri
, 7 months ago
String index out of range: 7

Solution icon of github
via GitHub by BioBG
, 4 months ago
String index out of range: 7

Solution icon of github
via GitHub by atoha
, 1 year ago
String index out of range: -7

Solution icon of github
String index out of range: 7

Solution icon of github
via GitHub by drenda
, 1 year ago
String index out of range: -7

Solution icon of googlegroups
via Google Groups by DTing, 2 months ago
String index out of range: -7

Solution icon of web
via JIRA by Martin Õunap, 1 year ago
String index out of range: -7

Solution icon of jfrog
via JFrog JIRA by Andrei Komarov, 2 weeks ago
String index out of range: -7

Solution icon of sourceforge
String index out of range: -7

Stack trace

  • java.lang.StringIndexOutOfBoundsException: String index out of range: 7 at java.lang.String.charAt(Unknown Source) at net.minecraft.item.crafting.CraftingManager.addRecipe(CraftingManager.java:266) at net.minecraftforge.fml.common.registry.GameRegistry.addShapedRecipe(GameRegistry.java:236) at net.minecraftforge.fml.common.registry.GameRegistry.addRecipe(GameRegistry.java:231) at com.student.emod.EMod.init(EMod.java:32) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at net.minecraftforge.fml.common.FMLModContainer.handleModStateEvent(FMLModContainer.java:518) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at com.google.common.eventbus.EventSubscriber.handleEvent(EventSubscriber.java:74) at com.google.common.eventbus.SynchronizedEventSubscriber.handleEvent(SynchronizedEventSubscriber.java:47) at com.google.common.eventbus.EventBus.dispatch(EventBus.java:322) at com.google.common.eventbus.EventBus.dispatchQueuedEvents(EventBus.java:304) at com.google.common.eventbus.EventBus.post(EventBus.java:275) at net.minecraftforge.fml.common.LoadController.sendEventToModContainer(LoadController.java:208) at net.minecraftforge.fml.common.LoadController.propogateStateMessage(LoadController.java:187) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at com.google.common.eventbus.EventSubscriber.handleEvent(EventSubscriber.java:74) at com.google.common.eventbus.SynchronizedEventSubscriber.handleEvent(SynchronizedEventSubscriber.java:47) at com.google.common.eventbus.EventBus.dispatch(EventBus.java:322) at com.google.common.eventbus.EventBus.dispatchQueuedEvents(EventBus.java:304) at com.google.common.eventbus.EventBus.post(EventBus.java:275) at net.minecraftforge.fml.common.LoadController.distributeStateMessage(LoadController.java:118) at net.minecraftforge.fml.common.Loader.initializeMods(Loader.java:692) at net.minecraftforge.fml.client.FMLClientHandler.finishMinecraftLoading(FMLClientHandler.java:291) at net.minecraft.client.Minecraft.startGame(Minecraft.java:521) at net.minecraft.client.Minecraft.run(Minecraft.java:356) at net.minecraft.client.main.Main.main(Main.java:117) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at net.minecraft.launchwrapper.Launch.launch(Launch.java:135) at net.minecraft.launchwrapper.Launch.main(Launch.java:28) at net.minecraftforge.gradle.GradleStartCommon.launch(Unknown Source) at GradleStart.main(Unknown Source)

Write tip

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

Users with the same issue

Samebug visitor profile picture
Unknown user
Once, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 2 weeks ago
Once, 1 month ago
Once, 1 month ago
35 more bugmates