Error: Failed to run "java -version", make sure that you have a JDK installed

Hi everyone,

I am very new to Ionic, I have set up android, jdk and other components that ionic needs.

For some reason whenever i try to build an app. it returns back with java version error.

I have installed both jdk 1.7 and 1.8 installed and checked. It doesn’t fix the problem.

I have attached the screenshot below.

Thanks,

Jay

guys if anyone of you know, please reply thanks.

[Solved] When I upgraded my windows Java got messed up. I have to uninstall everything and reinstall it back again. Kind stupid but it might help someone.

Uninstall what all packages?