How to Setup Environment Variables after Installing Java to Start Automation || Selenium || Java

Опубликовано: 07 Октябрь 2024
на канале: Knowledge Share
681
7

#Java #Environment
Watch below video to learn how to set up Environment variables after installing Java
   • How to Install Java in your System ||...  

In this video you will learn how to setup Environment variables after installing java.
Note : Without setting up environment variables you will not be able to write java programs and compile them
Please follow below steps and configuration details
========================================================
How to Setup Environment Variable for Java
========================================================

Press Windows + R and Input "CMD" and in Command prompt type below commands
check
java -version
javac
You will get error for javac command and for java -version you can still the version of java

Once you set up environment variable , you will not see errors for javac as well

In Windows - Search for Environment variables. . ( please see the video for full navigation )
Environment vairables
==============================
User Variables
1. Path :
Name : Path
C:\Program Files (x86)\Java\jdk1.8.0_261\bin
2. Class Path :
Name : classpath
C:\Program Files (x86)\Java\jdk1.8.0_261\lib
C:\Program Files (x86)\Java\jre1.8.0_261\lib

System Variables

Name : JAVA_HOME
Value : C:\Program Files (x86)\Java\jdk1.8.0_261