user3759600
user3759600

Reputation: 78

how to increase heap space of JVM in netbeans

On running my code it throws exception:

Exception in thread "AWT-EventQueue-1" java.lang.OutOfMemoryError: Java heap space

How to increase the heap space of JVM in netbeans 8??

Upvotes: 3

Views: 1803

Answers (1)

kaetzacoatl
kaetzacoatl

Reputation: 1469

Run->Set Project Configuration->Customize... You can enter your VM options in Run tab. Use the -Xmx[size] flag to increase the heap size. As size you can use for example 512m for 512MB or 2g for 2000MB.

Upvotes: 2

Related Questions