How To Set Path in Java - Javatpoint
How To Set Path in Java - Javatpoint
com/how-to-set-path-in-java
Home Java Programs OOPs String Exception Multithreading Collections JavaFX JSP
⇧ SCROLL TO TOP
If you are saving the Java source file inside the JDK/bin directory, the path is not required to be set because all the tools will be
available in the current directory.
However, if you have your Java file outside the JDK/bin folder, it is necessary to set the path of JDK.
1. Temporary
2. Permanent
For Example:
⇧ SCROLL TO TOP
◦ Go to MyComputer properties -> advanced tab -> environment variables -> new tab of user variable -> write path in variable
name -> write path of bin folder in variable value -> ok -> ok -> ok
For Example:
1) Go to MyComputer properties
⇧ SCROLL TO TOP
⇧ SCROLL TO TOP
⇧ SCROLL TO TOP
⇧ SCROLL TO TOP
8) Click on ok button
9) Click on ok button
⇧ SCROLL TO TOP
Now your permanent path is set. You can now execute any program of java from any drive.
Setting path in Linux OS is the same as setting the path in the Windows OS. But, here we use the export tool rather than set. Let's see how to set
path in Linux OS:
export PATH=$PATH:/home/jdk1.6.01/bin/
Here, we have installed the JDK in the home directory under Root (/home).
← Prev
⇧ SCROLL TO TOP Next →
Feedback
⇧ SCROLL TO TOP
Splunk tutorial SPSS tutorial Swagger tutorial T-SQL tutorial Tumblr tutorial React tutorial
Splunk SPSS Swagger Transact-SQL Tumblr ReactJS
Regex tutorial Reinforcement R Programming RxJS tutorial React Native Python Design
Regex learning tutorial tutorial RxJS tutorial Patterns
Reinforcement R Programming React Native Python Design
Learning Patterns
Preparation
Trending Technologies
Artificial AWS Tutorial Selenium tutorial Cloud Computing Hadoop tutorial ReactJS Tutorial
Intelligence AWS Selenium tutorial Hadoop ReactJS
Tutorial Cloud Computing
Artificial
Intelligence
Data Science Angular 7 Tutorial Blockchain Git Tutorial Machine Learning DevOps Tutorial
Tutorial Angular 7 Tutorial Git Tutorial DevOps
Data Science Blockchain Machine Learning
⇧ SCROLL TO TOP
Sponsored
B.Tech / MCA
DBMS tutorial Data Structures DAA tutorial Operating System Computer Compiler Design
DBMS tutorial DAA tutorial Network tutorial tutorial
Data Structures Operating System Computer Network Compiler Design
Cyber Security Automata Tutorial C Language C++ tutorial Java tutorial .Net Framework
tutorial Automata tutorial C++ Java tutorial
Cyber Security C Programming .Net
Python tutorial List of Programs Control Systems Data Mining Data Warehouse
Python Programs tutorial Tutorial Tutorial
Control System Data Mining Data Warehouse
⇧ SCROLL TO TOP