Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

CLASSPATH problem in Java Web server2.0

Status
Not open for further replies.

sami

Programmer
Nov 29, 2000
2
AU
in order to compile any servlet with java web server, one has to include servlet.jar in the CLASSPATH.
so I set up my CLASSPATH variable in autoexec.bat like
set CLASSPATH = c:\JavaWebServer2.0\lib\servlet.jar;

now if i try to compile my servlet, javac gives me error saying that packages javax.servert.*; & javax.servlet.http.*; not found, but If I run javac like this
javac -classpath c:\JavaWebServer2.0\lib\servlet.jar first.java
this things get compiled.
Does anybody has a clue what I am doing wrong
Thanx in advance
Sami
 
You are overwriting CLASSPATH with only a single jar file. This may make some difference, so try:

CLASSPATH = %CLASSPATH%;c:\JavaWebServer2.0\lib\servlet.jar
 
Give this command:
set classpath=%classpath%;C:\Javawebserver2.0\lib\servlet.jar;
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top