Error starting Java virtual machine. Java exception thrown

I'm a newbie. I am trying to run a JDBC java program in Eclipse with a tomcat server. But when I run the program, a popup window appears "Java virtual machine launcher" with "Error java error error". I think compiling code is great.

So how do I fix this problem. When I browse different websites, some say that I have to install java again. It's true. Please help me with the answers.

Thanks in advance

+3
source share
7 answers

For me, I just delete my metaData folder and run eclipse with the import of all the necessary project files and libraries.

+3
source

Cause of the problem

, eclipse ( JVM ). .metadata .

eclipse, , .metadata eclipse. , , .metadata JVM.

+2

- java eclipse. - . . Java - , "java".

0

, .metadata, . , java. , java.example.com . com.java.example.

0

, , . ant (1.10) JRE (JDK 1.7). -, ant 1.10 JDK 1.7. JRE JRE 1.8.0 .

> > Java > JRE > ... > java 1.8, . > OK

0

I ran into the same problem with my Eclipse (currently using Eclipse Photon). Although the attempt to delete the metadata did not work, since I work on JDK 1.7, it seems that the current version of Ant is Ant 1.10, so setting ANT to 1.9 solved the problem.

Go to Windows> "Preferences"> "Ant"> "Runtime"> "Ant Home" and select the version of Ant you need.

0
source

In my case, JDK 1.7 and JRE 1.8 were present in the Java build path library >>. I uninstalled JDK 1.7, this solves my problem.

0
source

All Articles