Search code examples
javajava-mememory-leaks

Netbeans getting java.lang.OutOfMemoryError


I'm executing my j2me project and I'm getting this error:

TRACE: <at java.lang.OutOfMemoryError>, Exception caught in Display class
java.lang.OutOfMemoryError
   (stack trace incomplete)

My .jar size is 612KB and I had search and found this: Java heap space in netbeans.. but I've increased the heap size already!

But as shown in this case, I am not able to find VMoption in properties-Run.

Where can I get the screenshow or the exact file where I have to increase the heap size of Netbeans?


Solution

  • You can use obfuscator to obfuscate your code . and 612 kb is considered as a large file for java-me.

    You can increase memory and made it working but it will fail in real time env. so I would suggest you to work in dev with real time conf.

    right click your project > properties > obfuscating > obfuscation level > high >build your app