How to Set Environment Variable for Java?

Follow below steps to set environment variable (Make sure JDK is installed before you follow these steps.


Go to Desktop and Right Click on My Computer (or This System) and select Properties.

 
Click on Advanced System Settings.                                                                                                                                                  

Now, in Advanced click on Environment Variables....
                                                                             

Click on New in User Variables.   
                                                                                                                                                                           
Enter Variable Name as "path".
Set Variable Value as below.
For 64 bit Windows OS  : "C:\Program Files\Java\jdk-15.0.1\bin"
For 32 bit Windows OS  : "C:\Program Files (x86)\Java\jdk-15.0.1\bin"
Note : - Kindly make sure to go to path as per your system and don't copy the same path. You have to go to C>Program files>Java>jdk-version>bin 

                   
                                                      
Click OK.
Repeat step 5 & 6 for System Variables.    
                                                                                                 
 

Comments

Popular posts from this blog

Constants

Data Types in C Programming

Identifiers