如何检查计算机上是否安装了java [英] How to check whether java is installed on the computer
本文介绍了如何检查计算机上是否安装了java的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在尝试在客户端计算机上安装java windows应用程序。我想检查机器上是否安装了
requried JRE。我想通过java程序检查它而不是通过cmd命令
I am trying to install java windows application on client machine.I want to check whether requried JRE is installed on the machine or not. I want to check it by java program not by cmd command
推荐答案
如果您使用的是Windows或Linux操作系统,则输入命令提示/终端
if you are using windows or linux operating system then type in command prompt / terminal
java -version
如果正确安装了java,那么你将获得类似这样的东西
If java is correctly installed then you will get something like this
java version "1.7.0_25"
Java(TM) SE Runtime Environment (build 1.7.0_25-b15)
Java HotSpot(TM) Client VM (build 23.25-b01, mixed mode, sharing)
附注:在Windows操作系统上安装Java后,PATH变量被更改为添加java.exe,所以你需要重新打开cmd.exe才能重新加载PATH变量。
修改:
CD先到路径...
CD to the path first...
cd C:\ProgramData\Oracle\Java\javapath
java -version
这篇关于如何检查计算机上是否安装了java的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文