PDA

View Full Version : Setting up Path & Class Path in autoexec.bat


AryaputrA
06-07-2003, 07:18 AM
Hello,

Can anyone help me

I just installed j2sdk1.4.1_03 on a win98SE, and i was told to set the path and class path in the autoexec.bat, but i can't seem to run the javac command,

my Initial setting was :
PATH C:\j2sdk1.4.1_03\bin;%PATH%
SET CLASSPATH=.;C:\j2sdk1.4.1_03\lib\tools.jar

with the setting above i can't run the javac command but i can do the java -version command, then i did this

PATH C:\j2sdk1.4.1_03\bin
SET CLASSPATH=.;C:\j2sdk1.4.1_03\lib\tools.jar

I removed the ;%PATH% and the end of the line. but now whenever i restart or start my windows i'll get error as can't find win.com, and i can run the javac command with this setting

so everytime i have to cd windows and run win, is there a better solution or remedy to it.

I've installed j2sdk1.4.1_03 to C:\j2sdk1.4.1_03
my javac.exe is in the C:\j2sdk1.4.1_03\bin folder

Help much appreciated

Celtboy
06-11-2003, 08:35 PM
Try:

SET PATH=%PATH%;C:\j2sdk1.4.1_03\bin
SET CLASSPATH=.;C:\j2sdk1.4.1_03\lib\tools.jar


That might fix your cd windows, win problem too.

AryaputrA
06-12-2003, 03:52 AM
Thanks a lot Celtboy, that helped a lot :thumbsup: