_Esam
asked on
How do I set PATH, CLASSPATH, JAVA_HOME in Windows ME ?
Ok,
I installed jdk1.5.0_02 in the directory C:
It automatically installed at C:\Program Files\Java\jdk1.5.0_02\bin ??
So, I assume my jdk directory is c:\Program Files\Java ?
I set the path variable as (in the autoexec under C: not autoexec.bat ??? )
SET PATH = %PATH%; C:\PROGRAM~1\JAVA\JDK1.5.0 _02\BIN ( i added this part)
//the below part I left alone since it was already there for whatever reason..
;C:\WINDOWS;C:\WINDOWS\COM MAND;C:\AT F
Now, how do I set the classpath ??
How do I set the JAVA_HOME ?
Thanks.
_Esam
I installed jdk1.5.0_02 in the directory C:
It automatically installed at C:\Program Files\Java\jdk1.5.0_02\bin
So, I assume my jdk directory is c:\Program Files\Java ?
I set the path variable as (in the autoexec under C: not autoexec.bat ??? )
SET PATH = %PATH%; C:\PROGRAM~1\JAVA\JDK1.5.0
//the below part I left alone since it was already there for whatever reason..
;C:\WINDOWS;C:\WINDOWS\COM
Now, how do I set the classpath ??
How do I set the JAVA_HOME ?
Thanks.
_Esam
ASKER
Ok, looks good but I need to make sure :
As I was informed earlier >>
In Windows ME , I can't add long directory names like Program Files ..
I had to quote it as "\Program Files" ? even to cd to Program Files
How does this apply to this ????
***************
These are taken from the bottom link above...
C:>set JAVA_HOME=C:\jdk1.3.1
You then have to update your PATH variable by appending C:\jdk1.3.1\bin. If JAVA_HOME has been properly set, you can enter the following: C:>set PATH=%PATH%;%JAVA_HOME%\bi n
***************
If the full directory path to my \bin is :
C:\Program Files\Java\jdk1.5.0_02\bin
What's my JAVA_HOME=?
C:>set AVA_HOME = "C:\Program Files\Java\jdk1.5.0_02" (WITH OR WITHOUT QUOTES ?)
AND MY PATH IS:
C:>set PATH=%PATH%;%JAVA_HOME%\bi n
_Esam
As I was informed earlier >>
In Windows ME , I can't add long directory names like Program Files ..
I had to quote it as "\Program Files" ? even to cd to Program Files
How does this apply to this ????
***************
These are taken from the bottom link above...
C:>set JAVA_HOME=C:\jdk1.3.1
You then have to update your PATH variable by appending C:\jdk1.3.1\bin. If JAVA_HOME has been properly set, you can enter the following: C:>set PATH=%PATH%;%JAVA_HOME%\bi
***************
If the full directory path to my \bin is :
C:\Program Files\Java\jdk1.5.0_02\bin
What's my JAVA_HOME=?
C:>set AVA_HOME = "C:\Program Files\Java\jdk1.5.0_02" (WITH OR WITHOUT QUOTES ?)
AND MY PATH IS:
C:>set PATH=%PATH%;%JAVA_HOME%\bi
_Esam
>> I had to quote it as "\Program Files" ? even to cd to Program Files
>> WITH OR WITHOUT QUOTES ?
Then you certainly need the qoutes in
set JAVA_HOME = "C:\Program Files\Java\jdk1.5.0_02"
too
>> WITH OR WITHOUT QUOTES ?
Then you certainly need the qoutes in
set JAVA_HOME = "C:\Program Files\Java\jdk1.5.0_02"
too
ASKER
This is confusing:
Isn't JAVA_HOME and PATH are related?
If I set>
set JAVA_HOME = "C:\Program Files\Java\jdk1.5.0_02"
What is me Set PATH =?
set PATH = %JAVA_HOME%\bin ????
_Esam
Isn't JAVA_HOME and PATH are related?
If I set>
set JAVA_HOME = "C:\Program Files\Java\jdk1.5.0_02"
What is me Set PATH =?
set PATH = %JAVA_HOME%\bin ????
_Esam
PATH and JAVA_HOME are just two different environment variables that need to be set.
- Windows ME uses the PATH variable (e.g. to search for executables you start)
- Java uses the JAVA_HOME variable
- Windows ME uses the PATH variable (e.g. to search for executables you start)
- Java uses the JAVA_HOME variable
ASKER
>>>Windows ME uses the PATH variable (e.g. to search for executables you start)
This makes sense as Windows ME will eventually find it at:
C:\Program Files\Java\jdk1.5.0_02 from JAVA_HOME and then
\bin from PATH
As in:
set JAVA_HOME = "C:\Program Files\Java\jdk1.5.0_02"
What is me Set PATH =?
set PATH = %JAVA_HOME%\bin
>>>Java uses the JAVA_HOME variable
And what does this variable do?
Where does it direct to ? executables or ??? not clear ?
FINALLY,
I can't seem to use the command line to set the variables ....
Do I have to use the programs/access/........
Or Can I use a command line...
If so, ? (Tutorials on Windows ME is so VAGUE)
_Esam
This makes sense as Windows ME will eventually find it at:
C:\Program Files\Java\jdk1.5.0_02 from JAVA_HOME and then
\bin from PATH
As in:
set JAVA_HOME = "C:\Program Files\Java\jdk1.5.0_02"
What is me Set PATH =?
set PATH = %JAVA_HOME%\bin
>>>Java uses the JAVA_HOME variable
And what does this variable do?
Where does it direct to ? executables or ??? not clear ?
FINALLY,
I can't seem to use the command line to set the variables ....
Do I have to use the programs/access/........
Or Can I use a command line...
If so, ? (Tutorials on Windows ME is so VAGUE)
_Esam
>> set PATH = %JAVA_HOME%\bin
Sets the PATH variable = the content of the JAVA_HOME variable appended with "\bin"
JAVA_HOME is the path to your JDK installation
>> Can I use a command line
I quote from my 2nd link:
Windows Me
Go to the Start Menu, then choose Programs, Accessories, System Tools and System Information. A window titled "Microsoft Help and Support" should appear. Select the Tools menu, and choose the System Configuration Utility. Go to the Environment tab where you can edit the PATH variable. Append the value ;C:\jdk1.3.1\bin. Once you have changed and saved the value, you will be prompted to reboot.
Sets the PATH variable = the content of the JAVA_HOME variable appended with "\bin"
JAVA_HOME is the path to your JDK installation
>> Can I use a command line
I quote from my 2nd link:
Windows Me
Go to the Start Menu, then choose Programs, Accessories, System Tools and System Information. A window titled "Microsoft Help and Support" should appear. Select the Tools menu, and choose the System Configuration Utility. Go to the Environment tab where you can edit the PATH variable. Append the value ;C:\jdk1.3.1\bin. Once you have changed and saved the value, you will be prompted to reboot.
ASKER
As suggested in the 2nd link:
I appended this to the PATH variable > C:\Progra~1\Java\jdk1.5.0_ 02\bin
Progra~1 is like Program Files (I guess they mean the same to the Win ME)
I appende this to the JAVA_HOME > C:\PROGRA~1\Java\jdk1.5.0_ 02
How come I am not able to compile a java program from the command line?
If my myRMIInterface.java is at > C:\RMI\myRMIInterface.java
and I am at C:\RMI> and command javac myRMIInterface.java
it say bad command...((((((((I had it worked with Win 2000 earlier))))))))
Don't know what's wrong with Win ME (I can't change to Win 2000 right now)
_Esam
I appended this to the PATH variable > C:\Progra~1\Java\jdk1.5.0_
Progra~1 is like Program Files (I guess they mean the same to the Win ME)
I appende this to the JAVA_HOME > C:\PROGRA~1\Java\jdk1.5.0_
How come I am not able to compile a java program from the command line?
If my myRMIInterface.java is at > C:\RMI\myRMIInterface.java
and I am at C:\RMI> and command javac myRMIInterface.java
it say bad command...((((((((I had it worked with Win 2000 earlier))))))))
Don't know what's wrong with Win ME (I can't change to Win 2000 right now)
_Esam
>> I appended this to the PATH variable > C:\Progra~1\Java\jdk1.5.0_ 02\bin
I hope you typed in the version without the ~.
That is:
set JAVA_HOME = "C:\Program Files\Java\jdk1.5.0_02"
followed by
set PATH = %PATH%;%JAVA_HOME%\bin
Did you type this? Litterally?
What output does these two produce? Can you post?
C:\RMI>java -version
C:\RMI>path
I hope you typed in the version without the ~.
That is:
set JAVA_HOME = "C:\Program Files\Java\jdk1.5.0_02"
followed by
set PATH = %PATH%;%JAVA_HOME%\bin
Did you type this? Litterally?
What output does these two produce? Can you post?
C:\RMI>java -version
C:\RMI>path
ASKER
C:\WINDOWS>cd ..
C:\>cd rmi
C:\RMI>path
PATH=C:\WINDOWS;C:\WINDOWS \COMMAND
C:\RMI>java -version
java version "1.5.0_02"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_02-b09)
Java HotSpot(TM) Client VM (build 1.5.0_02-b09, mixed mode)
C:\RMI>path
PATH=C:\WINDOWS;C:\WINDOWS \COMMAND
C:\RMI>
This is what I got now...
I thought I changed it ??
_Esam
C:\>cd rmi
C:\RMI>path
PATH=C:\WINDOWS;C:\WINDOWS
C:\RMI>java -version
java version "1.5.0_02"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_02-b09)
Java HotSpot(TM) Client VM (build 1.5.0_02-b09, mixed mode)
C:\RMI>path
PATH=C:\WINDOWS;C:\WINDOWS
C:\RMI>
This is what I got now...
I thought I changed it ??
_Esam
ASKER
This is what I have under >Start>Programs>Accessorie s>System Tools>
Tools>System Configuration Utilities>
FOR PATH variable:
C:\PROGRA~1\COMMON~1\MICRO S~1\MSInfo \;;C:\WIND OWS;C:\WIN DOWS\COMMA ND;C:\ATF; \bin; C:\Progra~1\Java\jdk1.5.0_ 02\bin
Tools>System Configuration Utilities>
FOR PATH variable:
C:\PROGRA~1\COMMON~1\MICRO
>> FOR PATH variable:
>> C:\PROGRA~1\COMMON~1\MICRO S~1\MSInfo \;;C:\WIND OWS;C:\WIN DOWS\COMMA ND;C:\ATF; \bin; C:\Progra~1\Java\jdk1.5.0_ 02\bin
1) You can delete that "\bin;" part
2) Looks OK
The fact that:
>> C:\RMI>java -version
produces
>> java version "1.5.0_02"
also proves it is OK.
I don't know why
>> C:\RMI>path
produces
>> PATH=C:\WINDOWS;C:\WINDOWS \COMMAND
Now,
>> I am at C:\RMI> and command javac myRMIInterface.java
>> it say bad command.
Can you check that you have the "javac.exe" file in C:\Program Files\Java\jdk1.5.0_02\bin ?
>> C:\PROGRA~1\COMMON~1\MICRO
1) You can delete that "\bin;" part
2) Looks OK
The fact that:
>> C:\RMI>java -version
produces
>> java version "1.5.0_02"
also proves it is OK.
I don't know why
>> C:\RMI>path
produces
>> PATH=C:\WINDOWS;C:\WINDOWS
Now,
>> I am at C:\RMI> and command javac myRMIInterface.java
>> it say bad command.
Can you check that you have the "javac.exe" file in C:\Program Files\Java\jdk1.5.0_02\bin
ASKER
I did delete the \bin part from the PATH.
I have javac not javac.exe in C:\Program Files\Java\jdk1.5.0_02\bin
I have javac not javac.exe in C:\Program Files\Java\jdk1.5.0_02\bin
>> I have javac not javac.exe
You have javac.exe
but your Windows ME is apparently configured *not* to show you the common extensions like exe
You have javac.exe
but your Windows ME is apparently configured *not* to show you the common extensions like exe
And you also have java(.exe) in that same directory?
ASKER
I just saved myRMIInterface.java file in the \bin and went to this directory from the command line..
and javac myRMIInterface.java and it did work..
This means somehow the path variable is not being set up ??
_Esam
and javac myRMIInterface.java and it did work..
This means somehow the path variable is not being set up ??
_Esam
ASKER
I have javac in the \bin directory not javac.exe ?
(If javac is meant to be javac.exe - I guess it is - since a program compiled)
_Esam
(If javac is meant to be javac.exe - I guess it is - since a program compiled)
_Esam
>> This means somehow the path variable is not being set up ??
Indeed.
Indeed.
Can you post the output of
C:\RMI>set
C:\RMI>set JAVA_HOME
C:\RMI>set path=%PATH3%;%JAVA_HOME%\b in
C:\RMI>set
C:\RMI>set
C:\RMI>set JAVA_HOME
C:\RMI>set path=%PATH3%;%JAVA_HOME%\b
C:\RMI>set
PATH3 was a typo.
Should have been PATH of course
Should have been PATH of course
ASKER
So how to solve it?
_Esam
_Esam
ASKER
I deleted that entry.
This is all I have at the autoexec >>
SET COMSPEC=C:\WINDOWS\COMMAND .COM
SET windir=C:\WINDOWS
SET winbootdir=C:\WINDOWS
SET PROMPT=$p$g
SET TEMP=C:\WINDOWS\TEMP
SET TMP=C:\WINDOWS\TEMP
SET PATH = C:\Progra~1\Java\jdk1.5.0_ 02\bin; C:\PROGRA~1\COMMON~1\MICRO S~1\MSInfo \;;C:\WIND OWS;C:\WIN DOWS\COMMA ND;C:\ATF
SET JAVA_HOME = C:\PROGRA~1\Java\jdk1.5.0_ 02
Anything suspicious?
_Esam
This is all I have at the autoexec >>
SET COMSPEC=C:\WINDOWS\COMMAND
SET windir=C:\WINDOWS
SET winbootdir=C:\WINDOWS
SET PROMPT=$p$g
SET TEMP=C:\WINDOWS\TEMP
SET TMP=C:\WINDOWS\TEMP
SET PATH = C:\Progra~1\Java\jdk1.5.0_
SET JAVA_HOME = C:\PROGRA~1\Java\jdk1.5.0_
Anything suspicious?
_Esam
Can you post the output of
C:\RMI>set
C:\RMI>set JAVA_HOME
C:\RMI>set path=%PATH%;%JAVA_HOME%\bi n
C:\RMI>set
C:\RMI>set
C:\RMI>set JAVA_HOME
C:\RMI>set path=%PATH%;%JAVA_HOME%\bi
C:\RMI>set
ASKER
C:\RMI>set JAVA_HOME
Syntax error
C:\RMI>set path=%PATH%;%JAVA_HOME%\bi
C:\RMI>
C:\RMI>set path=%PATH%;%JAVA_HOME%\bi
C:\RMI>set
COMSPEC=C:\WINDOWS\COMMAND
PROMPT=$p$g
TEMP=C:\WINDOWS\TEMP
TMP=C:\WINDOWS\TEMP
PATH = C:\WINDOWS;C:\WINDOWS\COMM
\PROGRA~1\COMMON~1\MICROS~
JAVA_HOME = C:\PROGRA~1\Java\jdk1.5.0_
winbootdir=C:\WINDOWS
windir=C:\WINDOWS
BLASTER=A220 I5 D1 T4 P330
CMDLINE=doskey /insert
PATH=C:\WINDOWS;C:\WINDOWS
C:\RMI>set path=%PATH%;%JAVA_HOME%\bi
ASKER
What is this?
BLASTER=A220 I5 D1 T4 P330
CMDLINE=doskey /insert
_Esam
BLASTER=A220 I5 D1 T4 P330
CMDLINE=doskey /insert
_Esam
>> What is this?
>> BLASTER=A220 I5 D1 T4 P330
Settings for your SoundBlaster sound card
>> CMDLINE=doskey /insert
Starts up the application doskey.
E.g. to make pressing <cursor up> work in a DOS-session
(=add on the command line what you previously typed)
>> BLASTER=A220 I5 D1 T4 P330
Settings for your SoundBlaster sound card
>> CMDLINE=doskey /insert
Starts up the application doskey.
E.g. to make pressing <cursor up> work in a DOS-session
(=add on the command line what you previously typed)
>> PATH = C:\WINDOWS;C:\WINDOWS\COMM AND; \bin; C:\Progra~1\Java\jdk1.5.0_ 02\bin; C:
>> \PROGRA~1\COMMON~1\MICROS~ 1\MSInfo\; C:\WINDOWS ;C:\WINDOW S\COMMAND; C:\ATF
>> JAVA_HOME = C:\PROGRA~1\Java\jdk1.5.0_ 02
1) JAVA_HOME is apparently not set
2) I see appear that useless "\bin;" again
3) C:\Progra~1\Java\jdk1.5.0_ 02\bin; is in the path, so javac should work
4) You have the things twice since you performed set path=... twice
I suggest the following.
1) Restart your computer
2) perform
C:\RMI>set
3) Post the result
4) Then we'll go together step by step
OK?
>> \PROGRA~1\COMMON~1\MICROS~
>> JAVA_HOME = C:\PROGRA~1\Java\jdk1.5.0_
1) JAVA_HOME is apparently not set
2) I see appear that useless "\bin;" again
3) C:\Progra~1\Java\jdk1.5.0_
4) You have the things twice since you performed set path=... twice
I suggest the following.
1) Restart your computer
2) perform
C:\RMI>set
3) Post the result
4) Then we'll go together step by step
OK?
ASKER
Ok, I restarted and performed C:\RMI>set and the result is:
C:\WINDOWS>cd ..
C:\>cd rmi
C:\RMI>set
PATH=C:\WINDOWS;C:\WINDOWS \COMMAND
COMSPEC=C:\WINDOWS\COMMAND .COM
PROMPT=$p$g
TEMP=C:\WINDOWS\TEMP
TMP=C:\WINDOWS\TEMP
PATH = C:\WINDOWS;C:\WINDOWS\COMM AND;C:\Pro gra~1\Java \jdk1.5.0_ 02\bin; C:\PROGRA
~1\COMMON~1\MICROS~1\MSInf o\;C:\WIND OWS;C:\WIN DOWS\COMMA ND;C:\ATF
JAVA_HOME = C:\PROGRA~1\Java\jdk1.5.0_ 02
winbootdir=C:\WINDOWS
windir=C:\WINDOWS
BLASTER=A220 I5 D1 T4 P330
CMDLINE=doskey /insert
C:\RMI>
_Esam
C:\WINDOWS>cd ..
C:\>cd rmi
C:\RMI>set
PATH=C:\WINDOWS;C:\WINDOWS
COMSPEC=C:\WINDOWS\COMMAND
PROMPT=$p$g
TEMP=C:\WINDOWS\TEMP
TMP=C:\WINDOWS\TEMP
PATH = C:\WINDOWS;C:\WINDOWS\COMM
~1\COMMON~1\MICROS~1\MSInf
JAVA_HOME = C:\PROGRA~1\Java\jdk1.5.0_
winbootdir=C:\WINDOWS
windir=C:\WINDOWS
BLASTER=A220 I5 D1 T4 P330
CMDLINE=doskey /insert
C:\RMI>
_Esam
ASKER
Looks like I have two PATH vairables ...
Should I delete the first one?
_Esam
Should I delete the first one?
_Esam
Oohhhhhhh. I see.
You have a "path" variable (the one used) and a "path " variable (the one you adapted but which isn't used)
Do the following:
[1] To delete the bad one:
C:\RMI>set path =
(Remark: including the space between 'path' and '=')
[2]
C:\RMI>set path=%PATH%;%JAVA_HOME%\bi n;
[3]
C:\RMI>set
And post the result
You have a "path" variable (the one used) and a "path " variable (the one you adapted but which isn't used)
Do the following:
[1] To delete the bad one:
C:\RMI>set path =
(Remark: including the space between 'path' and '=')
[2]
C:\RMI>set path=%PATH%;%JAVA_HOME%\bi
[3]
C:\RMI>set
And post the result
Remark for [2]: please ***NO*** space between 'path' and '='
I expect to see:
PATH=C:\WINDOWS;C:\WINDOWS \COMMAND;C :\Progra~1 \Java\jdk1 .5.0_02\bi n;
COMSPEC=C:\WINDOWS\COMMAND .COM
PROMPT=$p$g
TEMP=C:\WINDOWS\TEMP
TMP=C:\WINDOWS\TEMP
JAVA_HOME = C:\PROGRA~1\Java\jdk1.5.0_ 02
winbootdir=C:\WINDOWS
windir=C:\WINDOWS
BLASTER=A220 I5 D1 T4 P330
CMDLINE=doskey /insert
In that case your compilation should work
PATH=C:\WINDOWS;C:\WINDOWS
COMSPEC=C:\WINDOWS\COMMAND
PROMPT=$p$g
TEMP=C:\WINDOWS\TEMP
TMP=C:\WINDOWS\TEMP
JAVA_HOME = C:\PROGRA~1\Java\jdk1.5.0_
winbootdir=C:\WINDOWS
windir=C:\WINDOWS
BLASTER=A220 I5 D1 T4 P330
CMDLINE=doskey /insert
In that case your compilation should work
ASKER
Here it is:
C:\WINDOWS>cd ..
C:\>cd rmi
C:\RMI>set path=%PATH%;%JAVA_HOME%\bi n;
C:\RMI>set
COMSPEC=C:\WINDOWS\COMMAND .COM
PROMPT=$p$g
TEMP=C:\WINDOWS\TEMP
TMP=C:\WINDOWS\TEMP
PATH = C:\WINDOWS;C:\WINDOWS\COMM AND;C:\Pro gra~1\Java \jdk1.5.0_ 02\bin; C:\PROGRA
~1\COMMON~1\MICROS~1\MSInf o\;C:\WIND OWS;C:\WIN DOWS\COMMA ND;C:\ATF
JAVA_HOME = C:\PROGRA~1\Java\jdk1.5.0_ 02
winbootdir=C:\WINDOWS
windir=C:\WINDOWS
BLASTER=A220 I5 D1 T4 P330
CMDLINE=doskey /insert
PATH=C:\WINDOWS;C:\WINDOWS \COMMAND;\ BIN;
C:\RMI>
C:\WINDOWS>cd ..
C:\>cd rmi
C:\RMI>set path=%PATH%;%JAVA_HOME%\bi
C:\RMI>set
COMSPEC=C:\WINDOWS\COMMAND
PROMPT=$p$g
TEMP=C:\WINDOWS\TEMP
TMP=C:\WINDOWS\TEMP
PATH = C:\WINDOWS;C:\WINDOWS\COMM
~1\COMMON~1\MICROS~1\MSInf
JAVA_HOME = C:\PROGRA~1\Java\jdk1.5.0_
winbootdir=C:\WINDOWS
windir=C:\WINDOWS
BLASTER=A220 I5 D1 T4 P330
CMDLINE=doskey /insert
PATH=C:\WINDOWS;C:\WINDOWS
C:\RMI>
ASKER
There is some strange relationship (my misunderstanding perhaps) \bin at the last line
Perhaps due to JAVA_HOME?
_Esam
Perhaps due to JAVA_HOME?
_Esam
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Gee,
It finally worked...
I was able to compile a program on this directrory (C:\RMI>)
>>C:\RMI>set path = (It was all here :)
Thanks much zzynx and sorry for the trouble :)
A quick question >> not quite related .. but nobody is answering >>>
Here is the link>
https://www.experts-exchange.com/questions/21369401/Download-and-Install-TomCat-5-under-Windows-ME.html
Thanks.
_Esam
It finally worked...
I was able to compile a program on this directrory (C:\RMI>)
>>C:\RMI>set path = (It was all here :)
Thanks much zzynx and sorry for the trouble :)
A quick question >> not quite related .. but nobody is answering >>>
Here is the link>
https://www.experts-exchange.com/questions/21369401/Download-and-Install-TomCat-5-under-Windows-ME.html
Thanks.
_Esam
Thanks for accepting
>> It finally worked...
Pheew. That was a long one.
;°)
>> Here is the link
Sorry. I restrict myself to the java TA.
>> It finally worked...
Pheew. That was a long one.
;°)
>> Here is the link
Sorry. I restrict myself to the java TA.
ASKER
Thanks then....
_Esam
_Esam
(It's about Windows XP, but I guess that's no real problem)