• Post Reply Bookmark Topic Watch Topic
  • New Topic

VBScript Command Line  RSS feed

 
Rashmi Gupta
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I am trying to display java version using following program.
I am not getting the output. If any one can try this script.
I am using WHS 5.6.
Code is as below :
**************************************************************************
Set objShell = CreateObject("WScript.Shell")
set objScriptExec = objShell.run("C:\jdk1.3.1\bin\java.exe -version")
strIpConfig = objScriptExec.StdOut.ReadAll
WScript.Echo strIpConfig
**************************************************************************
Thanks
Rashmi.
 
Dirk Schreckmann
Sheriff
Posts: 7023
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to JavaRanch, Rashmi!
Since this is a Java forum...
The Java solution to your problem might include System.getProperty("java.version");
[ December 01, 2003: Message edited by: Dirk Schreckmann ]
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 66304
152
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Moving to Java in General (Intermediate).
bear
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!