How to set Path Temporary in Java
Set Temporary Path for a permanent path click here
Step 1:- Open your folder where you have placed the java file that you have compiled.
Step 2:- Click on the Location bar and delete it then type CMD Press Enter.
Step 3:- Now command prompt window appears on the screen.
Step 4:- Type Here set path=”C:\Program Files (x86)\Java\jdk1.8.0_121\bin”. before type this command copy the path in your system. if you have not installed java in your system then go to how to install java.
Step 5:- go to your C Drive or whose drive where you have installed java if default then go to C drive open program files folder( if you have 64-bit architecture system and you have installed 64-bit java then goto program files else goto program files (x86)) search java folder and open it now open bin folder, click on the location bar and copy the path.
Step 6:- Open the cmd window and paste the set path command press enter. you have set a temporary path if you have close this command prompt path has been clear. and if you have again opened a command prompt for compile or run java files then you have again set the path.