This week's book giveaway is in the Java in General forum.
We're giving away four copies of Helidon Revealed: A Practical Guide to Oracle’s Microservices Framework and have Michael Redlich on-line!
See this thread for details.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Liutauras Vilda
  • Ron McLeod
Sheriffs:
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Saloon Keepers:
  • Scott Selikoff
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
  • Frits Walraven
Bartenders:
  • Stephan van Hulst
  • Carey Brown

Setting up Paths Permanently

 
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator


C:\Documents and Settings\shr3dd3r\My Documents\javastuff>set path=%path%;C:\j2sdk1.4.2\bin;
C:\Documents and Settings\shr3dd3r\My Documents\javastuff>set classpath=%classpath%;.;


How do I set paths permanently? Is it even possible??
 
Ranch Hand
Posts: 121
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
u can set paths permanently by this way
1. if ur using windows go to Desktop-- MyComputer Right Click-->u will get a window called System Propertiesthere under Advanced TAB select EnvironmentVariables select new and create new variable as path n give ur path.
thanks
 
Carlos Montes
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Anurag_M:
Hi,
u can set paths permanently by this way
1. if ur using windows go to Desktop-- MyComputer Right Click-->u will get a window called System Propertiesthere under Advanced TAB select EnvironmentVariables select new and create new variable as path n give ur path.
thanks


In the Environment Variables Box
There is two boxes within it One of them say User variables for shr3dd3r
and you can add a new one, edit or delete.
Then there is a small box right underneath that says System Variables
and you can also add a new variable, edit or delete.
Which one of these do I add the new variable to?
and do I include the entire thing? such as
C:\Documents and Settings\shr3dd3r\My Documents\javastuff>set path=%path%;C:\j2sdk1.4.2\bin;
Or just the set path=%path%;C:\j2sdk1.4.2\bin;
Im lost here, thank you for any help
 
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
there are two option
1. set it in the system
2. create a batch file and run it whenever necessary
set it in the system
windows 95/98
add the two lines in the autoexec.bat
set it in the system
windows NT/2000
right click my computer select properties in that select advanced tab and in that environment variables you have two options here. add for current user or all users[system] select new and add the two lines one by one

create a batch file and run it whenever necessary
open Notepad paste those lines and save it as a batch file say paths.bat run this batch file when ever you go to command prompt instead of typing those two lines.
 
Carlos Montes
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Karthikeyan Rajendraprasad:

windows NT/2000
right click my computer select properties in that select advanced tab and in that environment variables you have two options here. add for current user or all users[system] select new and add the two lines one by one


Yes but Which lines do i include?
This one?
C:\Documents and Settings\shr3dd3r\My Documents\javastuff>set path=%path%;C:\j2sdk1.4.2\bin;
or just this set path=%path%;C:\j2sdk1.4.2\bin;
 
Ranch Hand
Posts: 327
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Carlos Montes:

Yes but Which lines do i include?
This one?
C:\Documents and Settings\shr3dd3r\My Documents\javastuff>set path=%path%;C:\j2sdk1.4.2\bin;
or just this set path=%path%;C:\j2sdk1.4.2\bin;


Hi Carlos,
I have the jdk installed under Win 2000. Try these steps:
1. Right click on the My Computer icon on your desktop
2. Select properties
3. Click the Advanced tab
4. Click the Environment Variables button
5. You should see a User variables window and a System variables window
6. Under the System variables window, do you have a variable named CLASSPATH ??
7. If not, then click the new button under the System variables window, If you do then make sure it has the stuff in steps 8 and 9
8. Under variable name, type this: CLASSPATH
9. Under the variable value, type the full path to the folder in which you will be saving all of your java work, which you've said is:
C:\Documents and Settings\shr3dd3r\My Documents\javastuff
As I understand it, having a classpath set allows you to import classes that you've already created and want to use in other programs.
But I personally think you also need to amend your path variable and add the full path to folder in which your java and javac exe's are located, which in your case is C:\j2sdk1.4.2\bin Just add C:\j2sdk1.4.2\bin; either to the front of your path variable OR ;C:\j2sdk1.4.2\bin to the end of it. Notice the semicolon placement of either option.
[ August 07, 2003: Message edited by: leo donahue ]
 
Karthikeyan Rajendraprasad
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
oops i missed that im post
when you click new it will have 2 text boxes
1. variable name
2. variable value
in name enter path
in value enter %path%;C:\j2sdk1.4.2\bin;
same way for classpath
in name enter classpath
in value enter %classpath%;.;
 
Ranch Hand
Posts: 305
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello,
Is it possible to set this classpath programatically too!!
Arun
 
Fire me boy! Cool, soothing, shameless self promotion:
Smokeless wood heat with a rocket mass heater
https://woodheat.net
reply
    Bookmark Topic Watch Topic
  • New Topic