how to setup java environment variables on Window 7 or window 8 or window xp

You should follow the below steps :

Step 1: Installation of JDK:  Don't forget to install JDK on your system (if  not installed) because any tomcat requires the  Java 1.5 (Java 5) and Java 1.6 (Java 6) and then set the class path (environment variable) of JDK.
Step 2: Setting the class path variable for JDK: Two methods are there to set the classpath.
  1. Set the class path using the following command.

    set PATH="C:\Program Files\Java\jdk1.5.0_08\bin";%PATH%
  2. The other way of setting the class path variable is:
First right click on the My Computer->properties->advance->Environment Variables->path.
Set bin directory path of JDK in the path variable.
Other operating System :

Windows XP
  1. Select Start, select Control Panel. double click System, and select the Advanced tab.
  2. Click Environment Variables. In the section System Variables, find the PATH environment variable and select it. Click Edit. If the PATH environment variable does not exist, click New.
  3. In the Edit System Variable (or New System Variable) window, specify the value of the PATH environment variable. Click OK. Close all remaining windows by clicking OK.
Windows Vista:
  1. From the desktop, right click the My Computer icon.
  2. Choose Properties from the context menu.
  3. Click the Advanced tab (Advanced system settings link in Vista).
  4. Click Environment Variables. In the section System Variables, find the PATH environment variable and select it. Click Edit. If the PATH environment variable does not exist, click New.
  5. In the Edit System Variable (or New System Variable) window, specify the value of the PATH environment variable. Click OK. Close all remaining windows by clicking OK.
Windows 7:
  1. From the desktop, right click the Computer icon.
  2. Choose Properties from the context menu.
  3. Click the Advanced system settings link.
  4. Click Environment Variables. In the section System Variables, find the PATH environment variable and select it. Click Edit. If the PATH environment variable does not exist, click New.
  5. In the Edit System Variable (or New System Variable) window, specify the value of the PATH environment variable. Click OK. Close all remaining windows by clicking OK.

Comments

Popular posts from this blog

Java Interfaces step by step solution with example

How to install Java on WINDOW operating system