In order to run java Programs one needs to set PATH and CLASSPATH in java. Let us see how we can set this. It is very easy just follow few steps and you are done.
You can install java from the given link: Download JAVA
If you don’t have JAVA installed in your system or you didn’t set the path then the command use to compile java will not be recognized. First install the JAVA setup and then proceed to set the class path.
STEP 1: Just right click on “MY COMPUTER” and select “Properties”.
STEP 2: You will be directed to the following screenshot.
STEP 3: Click on “Advanced System Setting”.
STEP 4: Now Click on the “Environment Variable”.
STEP 5: Click “NEW” Button and copy the address (Refer note at last of this post). Go to “My computer>C drive>Program files>Java>jdk1.6.0_20>bin” copy the address and paste it but do add DOT and SEMICOLON before. The setup version may vary so it is better to go to the directory and copy the address instead of writing from this tutorial
STEP 6: Click ok and you will see that it will get added to the window as shown.
STEP 7: Click “New” again and go to“My computer>C drive>Program files>Java>jdk1.6.0_20>lib”. Copy the address and paste it but do add DOT and SEMICOLON as shown.
STEP 8: Click ok and it will also gets added to the “Environment Variable” window. Click ok to close all the window and finally you are done. Now go to command prompt and type “JAVAC” and press ENTER you will see some list and this shows that you have successfully set up the PATH and CLASSPATH in JAVA.
NOTE: In order to copy address Please go to
Do the same procedure for individuals address.
This is how you can copy address. Thanks for your patience. Please give your comments regarding this post and do ask any query regarding this.
You can install java from the given link: Download JAVA
If you don’t have JAVA installed in your system or you didn’t set the path then the command use to compile java will not be recognized. First install the JAVA setup and then proceed to set the class path.
STEP 1: Just right click on “MY COMPUTER” and select “Properties”.
STEP 2: You will be directed to the following screenshot.
STEP 3: Click on “Advanced System Setting”.
STEP 4: Now Click on the “Environment Variable”.
STEP 5: Click “NEW” Button and copy the address (Refer note at last of this post). Go to “My computer>C drive>Program files>Java>jdk1.6.0_20>bin” copy the address and paste it but do add DOT and SEMICOLON before. The setup version may vary so it is better to go to the directory and copy the address instead of writing from this tutorial
STEP 6: Click ok and you will see that it will get added to the window as shown.
STEP 7: Click “New” again and go to“My computer>C drive>Program files>Java>jdk1.6.0_20>lib”. Copy the address and paste it but do add DOT and SEMICOLON as shown.
STEP 8: Click ok and it will also gets added to the “Environment Variable” window. Click ok to close all the window and finally you are done. Now go to command prompt and type “JAVAC” and press ENTER you will see some list and this shows that you have successfully set up the PATH and CLASSPATH in JAVA.
NOTE: In order to copy address Please go to
- “My computer>C drive>Program files>Java>jdk1.6.0_20>bin”
- “My computer>C drive>Program files>Java>jdk1.6.0_20>lib”
Do the same procedure for individuals address.
This is how you can copy address. Thanks for your patience. Please give your comments regarding this post and do ask any query regarding this.
4 comments:
Its Really working....... Thanks for this post.............
Thank u very much, i can n't believe it's really working. I was exhausted.
I will never forget to set classpath now
thank u so much
Thanks for the info... its really good...
its realy very informative. I was very worried and got frustrated and now i have this tutorial and it works..... Thanks... please post more...
Post a Comment