|
| ||||||||||
| Tags: bat, environment, script, variables |
![]() |
| | Thread Tools | Search this Thread |
|
#1
| |||
| |||
| set environment variables in script .bat
I'd like to make a script which sets JAVA_HOME in environment variables after the installation of java sdk. When I use the command "SET", JAVA_HOME is not in environment variables of the system, it is just set in envrironment variables of my script. How can I set JAVA_HOME in environment variables of my system (Windows 2003 server Standard Edition) ? Thanks |
|
#2
| |||
| |||
| Re: set environment variables in script .bat
On Mar 6, 7:51 am, "Creezeer" <nore...@noreply.com> wrote: > Hello every body, > > I'd like to make a script which sets JAVA_HOME in environment variables > after the installation of java sdk. > > When I use the command "SET", JAVA_HOME is not in environment variables of > the system, it is just set in envrironment variables of my script. > How can I set JAVA_HOME in environment variables of my system (Windows 2003 > server Standard Edition) ? > > Thanks There are a couple of options: Create the entry by importing a .reg file Write it directly to the registry [HKEY_LOCAL_MACHINE\SYSTEM \CurrentControlSet\Control\Session Manager\Environment] Use setx.exe from the resource kit Good luck. |
![]() |
|
| Thread Tools | Search this Thread |
| |
Similar Threads for: "set environment variables in script .bat" | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| What are an Environment Variables in PHP? | N I C K | Software Development | 5 | 21-02-2010 12:29 AM |
| c# environment variables | EULALIA | Software Development | 3 | 13-07-2009 02:23 PM |
| How to load/refresh environment variables WITHOUT leaving command prompt? | troy | Windows XP Support | 3 | 15-05-2009 11:33 PM |
| How to change/add environment variables from command line PERMANENTLY? | Moiz | Windows XP Support | 2 | 01-04-2009 05:46 PM |
| Setting environment variables? | Chaz | Vista Help | 3 | 18-01-2009 08:22 AM |